473,376 Members | 1,079 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,376 software developers and data experts.

moved from iis5 to iis6

Hi,

I have an asp.net webapp that works fine on my development machine,
win2k/iis5 however, when I move the site across to win2k3 / iis6 i get the
following error on postback of any page;

*------------------------------------------*
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set
to an instance of an object.
*------------------------------------------*

This error only ocours on postback of a page standard aspx pages with code
behind etc work fine, but on postback - bang. I assume its a setting
somewhere to tweak as it works fine on iis5.

I have tried IIS5 Issolation mode in IIS6 but it is still the same.

Any advice?

Many thanks

Terry.
Jun 6 '06 #1
5 2265
Without code and a line number it's impossible to debug. There's nothing
specific about iis 6 that jumps in my mind. NullReference errors tend to be
_very_ easy to debug though...If you deploy your pdb and get a line #,
you'll have it fixed in a couple minutes.

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/
"Terry Strachan" <te***@nospamthanksimfull.mertongroup.co.uk> wrote in
message news:O4**************@TK2MSFTNGP05.phx.gbl...
Hi,

I have an asp.net webapp that works fine on my development machine,
win2k/iis5 however, when I move the site across to win2k3 / iis6 i get the
following error on postback of any page;

*------------------------------------------*
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set
to an instance of an object.
*------------------------------------------*

This error only ocours on postback of a page standard aspx pages with code
behind etc work fine, but on postback - bang. I assume its a setting
somewhere to tweak as it works fine on iis5.

I have tried IIS5 Issolation mode in IIS6 but it is still the same.

Any advice?

Many thanks

Terry.

Jun 6 '06 #2
Thanks for the reply,
I have access to the code and line number (see below), however,
I am at a loss as to why the exact same webpages run on my IIS5 machine.
Private Sub btnLogin_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnLogin.Click

Dim oWebUser As cmvWebUser = New cmvWebUser
Dim oUser As cmvUser = New cmvUser

If tbUserName.Text = "" Or tbPassword.Text = "" Then
lblMissing.Text = "Please enter user ID and password"
Else
oUser = oWebUser.LogOn(tbUserName.Text, tbPassword.Text,
Session.SessionID)

Dim oRegistration As cmvRegistration = New cmvRegistration
*-->>>If oUser.Security = "ADMIN" Then

oRegistration =
oRegistration.GetRegistration(tbUserName.Text)

If oRegistration.Approved = "A" Then
Response.Redirect("/client/activation.aspx?UserID=" &
tbUserName.Text)
End If

If oRegistration.Approved = "N" Then
Response.Redirect("/client/approve.aspx")
End If

End If

End Sub
The oWebUser.LogOn method interacts with our back office system (mvbase) to
verify the login details. I have a telnet session logged on to the same
port so I can watch the transaction however, it doesnt fire.

It stops at the oUser.Security = "ADMIN" line, which the object is created
a few lines before from class cmvUser.

I am trying to set up remote debugging to see what is and isnt firing, but
windows 2000, VSNet 2003 on my development machine and Win 2003 and iis6 on
my server are giving me all sorts of problems and many hours googling... I
am at a stage now where I need to install the remote debugging components on
the server, only to find the disc isnt on site. It will have to wait till
tmrw.

Terry.

"Karl Seguin [MVP]" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME
net> wrote in message news:uR**************@TK2MSFTNGP04.phx.gbl...
Without code and a line number it's impossible to debug. There's nothing
specific about iis 6 that jumps in my mind. NullReference errors tend to be _very_ easy to debug though...If you deploy your pdb and get a line #,
you'll have it fixed in a couple minutes.

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/
"Terry Strachan" <te***@nospamthanksimfull.mertongroup.co.uk> wrote in
message news:O4**************@TK2MSFTNGP05.phx.gbl...
Hi,

I have an asp.net webapp that works fine on my development machine,
win2k/iis5 however, when I move the site across to win2k3 / iis6 i get the following error on postback of any page;

*------------------------------------------*
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
*------------------------------------------*

This error only ocours on postback of a page standard aspx pages with code behind etc work fine, but on postback - bang. I assume its a setting
somewhere to tweak as it works fine on iis5.

I have tried IIS5 Issolation mode in IIS6 but it is still the same.

Any advice?

Many thanks

Terry.


Jun 6 '06 #3
Terry Strachan wrote:
Thanks for the reply,
I have access to the code and line number (see below), however,
I am at a loss as to why the exact same webpages run on my IIS5 machine.
Private Sub btnLogin_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnLogin.Click

Dim oWebUser As cmvWebUser = New cmvWebUser
Dim oUser As cmvUser = New cmvUser

If tbUserName.Text = "" Or tbPassword.Text = "" Then
lblMissing.Text = "Please enter user ID and password"
Else
oUser = oWebUser.LogOn(tbUserName.Text, tbPassword.Text,
Session.SessionID)

Dim oRegistration As cmvRegistration = New cmvRegistration
*-->>>If oUser.Security = "ADMIN" Then
If the logon method fails wouldn't oUser be null?


oRegistration =
oRegistration.GetRegistration(tbUserName.Text)

If oRegistration.Approved = "A" Then
Response.Redirect("/client/activation.aspx?UserID=" &
tbUserName.Text)
End If

If oRegistration.Approved = "N" Then
Response.Redirect("/client/approve.aspx")
End If

End If

End Sub
The oWebUser.LogOn method interacts with our back office system (mvbase) to
verify the login details. I have a telnet session logged on to the same
port so I can watch the transaction however, it doesnt fire.

It stops at the oUser.Security = "ADMIN" line, which the object is created
a few lines before from class cmvUser.

I am trying to set up remote debugging to see what is and isnt firing, but
windows 2000, VSNet 2003 on my development machine and Win 2003 and iis6 on
my server are giving me all sorts of problems and many hours googling... I
am at a stage now where I need to install the remote debugging components on
the server, only to find the disc isnt on site. It will have to wait till
tmrw.

Terry.

"Karl Seguin [MVP]" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME
net> wrote in message news:uR**************@TK2MSFTNGP04.phx.gbl...
Without code and a line number it's impossible to debug. There's nothing
specific about iis 6 that jumps in my mind. NullReference errors tend to

be
_very_ easy to debug though...If you deploy your pdb and get a line #,
you'll have it fixed in a couple minutes.

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/
"Terry Strachan" <te***@nospamthanksimfull.mertongroup.co.uk> wrote in
message news:O4**************@TK2MSFTNGP05.phx.gbl...
Hi,

I have an asp.net webapp that works fine on my development machine,
win2k/iis5 however, when I move the site across to win2k3 / iis6 i get the following error on postback of any page;

*------------------------------------------*
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
*------------------------------------------*

This error only ocours on postback of a page standard aspx pages with code behind etc work fine, but on postback - bang. I assume its a setting
somewhere to tweak as it works fine on iis5.

I have tried IIS5 Issolation mode in IIS6 but it is still the same.

Any advice?

Many thanks

Terry.


Jun 6 '06 #4
Ya, again, I'm not sure what it is about IIS6..but your oWebUser.LogOn is
obviously returning null. I can't offer much more help other than suggest
that you look into that method and figure out under what circumstances it'd
be null...

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/
"Terry Strachan" <te***@nospamthanksimfull.mertongroup.co.uk> wrote in
message news:%2****************@TK2MSFTNGP05.phx.gbl...
Thanks for the reply,
I have access to the code and line number (see below), however,
I am at a loss as to why the exact same webpages run on my IIS5 machine.
Private Sub btnLogin_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnLogin.Click

Dim oWebUser As cmvWebUser = New cmvWebUser
Dim oUser As cmvUser = New cmvUser

If tbUserName.Text = "" Or tbPassword.Text = "" Then
lblMissing.Text = "Please enter user ID and password"
Else
oUser = oWebUser.LogOn(tbUserName.Text, tbPassword.Text,
Session.SessionID)

Dim oRegistration As cmvRegistration = New cmvRegistration
*-->>>If oUser.Security = "ADMIN" Then

oRegistration =
oRegistration.GetRegistration(tbUserName.Text)

If oRegistration.Approved = "A" Then
Response.Redirect("/client/activation.aspx?UserID=" &
tbUserName.Text)
End If

If oRegistration.Approved = "N" Then
Response.Redirect("/client/approve.aspx")
End If

End If

End Sub
The oWebUser.LogOn method interacts with our back office system (mvbase)
to
verify the login details. I have a telnet session logged on to the same
port so I can watch the transaction however, it doesnt fire.

It stops at the oUser.Security = "ADMIN" line, which the object is
created
a few lines before from class cmvUser.

I am trying to set up remote debugging to see what is and isnt firing, but
windows 2000, VSNet 2003 on my development machine and Win 2003 and iis6
on
my server are giving me all sorts of problems and many hours googling...
I
am at a stage now where I need to install the remote debugging components
on
the server, only to find the disc isnt on site. It will have to wait till
tmrw.

Terry.

"Karl Seguin [MVP]" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME
net> wrote in message news:uR**************@TK2MSFTNGP04.phx.gbl...
Without code and a line number it's impossible to debug. There's nothing
specific about iis 6 that jumps in my mind. NullReference errors tend to

be
_very_ easy to debug though...If you deploy your pdb and get a line #,
you'll have it fixed in a couple minutes.

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/
"Terry Strachan" <te***@nospamthanksimfull.mertongroup.co.uk> wrote in
message news:O4**************@TK2MSFTNGP05.phx.gbl...
> Hi,
>
> I have an asp.net webapp that works fine on my development machine,
> win2k/iis5 however, when I move the site across to win2k3 / iis6 i get the > following error on postback of any page;
>
> *------------------------------------------*
> Object reference not set to an instance of an object.
> Description: An unhandled exception occurred during the execution of
> the
> current web request. Please review the stack trace for more information
> about the error and where it originated in the code.
> Exception Details: System.NullReferenceException: Object reference not set > to an instance of an object.
> *------------------------------------------*
>
> This error only ocours on postback of a page standard aspx pages with code > behind etc work fine, but on postback - bang. I assume its a setting
> somewhere to tweak as it works fine on iis5.
>
> I have tried IIS5 Issolation mode in IIS6 but it is still the same.
>
> Any advice?
>
> Many thanks
>
> Terry.
>
>



Jun 6 '06 #5
I now have remote debugging set up and working and you were both right - the
logon method was returning a null. The problem had nothing to do with IIS,
or the OS, or VS... My error trapping wasn't very good.

The problem lay with the third party database connection software (mv.net) I
had configured it slightly wrong on the server but right on my test machine.

Ooops

Thanks for your help.

Terry.

"Karl Seguin [MVP]" <karl REMOVE @ REMOVE openmymind REMOVEMETOO . ANDME
net> wrote in message news:uF**************@TK2MSFTNGP03.phx.gbl...
Ya, again, I'm not sure what it is about IIS6..but your oWebUser.LogOn is
obviously returning null. I can't offer much more help other than suggest
that you look into that method and figure out under what circumstances it'd be null...

Karl

--
http://www.openmymind.net/
http://www.fuelindustries.com/

<snip>

Jun 7 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: David Lozzi | last post by:
I have an ASP app that grabs the logon user, and then I use GetObject to query the user's security groups. On a Windows 2000 server running IIS5, this works excellent. I then copied it to a...
6
by: Areid_philombios | last post by:
I have a custom File management ASP application that handles Large File uploads and download from a database (30 - 40 MB files) The application works fine on IIS5 but when I relocate it to IIS6 i get...
3
by: John Chertudi | last post by:
We are poised to migrate about 600 ASP sites from a single IIS5 server to a new pair of IIS6 servers. However, it appears that all files with includes like: <!-- #include...
1
by: Brian Henry | last post by:
Is there any problems with writing on IIS6 with ASP.NET and publishing onto IIS5 on W2K with ASP.NET? (like xp pro to 2k server) any compatability problems?
0
by: Mark B | last post by:
Our webhost (www.usbusinessweb.net) had a W2K IIS5 server crash after a scheduled hard-boot occurred during a ms-security patch install overnight. They couldn't get the server working again so they...
1
by: eccsolutions | last post by:
Any help on this topic is greatly appreciated. Currently we are running ASP.NET 1.1 in production with over 30+ 1.1 applications. Recently we have written several applications using ASP.NET...
3
by: | last post by:
Hi All, I have several classic asp pages in site that were originally programmed with Visual Interdev (or Visual Web Developer Alpha... remember that?). The pages use the Script Library objects...
0
by: Brian | last post by:
I have an ASP.NET 1.1 application that does URL rewriting via a custom HttpModule. We recently migrated this application from Win2k/IIS5 to Win2k3/IIS6. In IIS5, I added a wildcard application map...
1
by: Luwk | last post by:
I have an application that communicates with the Company's Active Directory to get the OU of the users. This said application is an ASP.Net web site and has the Windows Authentication enabled. ....
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.