response.redirect not working - HELP!

O

ODAN

We are testing a ASP.NET application in Visual Studion 2003 and written in
C#. One of the pages that register new users on this application fails to
redirect to another page when the button is clicked. On the page there is a
button that has been code to save to database and also redirect to the login
page. When you fill out the form and click on this page, it saves the data
into the database but it does nothing after that, it just sits there on the
same page. We checked everytihng in the code and the web.config file. The
web applicaiton is working good on the development workstation (Win XP), but
not working on the server running Windows Server 2003 IIS6. Please help? Any
ideas?


try

{

if(Session["RegistrantID"]!=null)

{

divusername.Visible=false;

string registrantId=Session["RegistrantID"].ToString;

string userName=Session["username"].ToString();

if(WRTSPublic.DataAccess.DataAccess.UpdateRegistrantDetails(registrantId,userName,RegistantObj,dsCompenOrg,selectedCountiesArr))

{

Response.Redirect(TrainingURL,false);

}

}

else

{

if(WRTSPublic.DataAccess.DataAccess.InsertRegistrantDetails(RegistantObj,dsCompenOrg,selectedCountiesArr))

{

Response.Redirect(IntroductionURL,false);

}

}

}

catch(Exception ex)

{

ExceptionCatch.RegisterLog(ex.Message);

}

}
 
O

ODAN

The uri was valid. The problem was the smartnav. we disable smart nav and
everything works good now.
Alvin Bruney said:
most likely trainingurl uri is not valid

--

________________________
Warm regards,
Alvin Bruney [MVP ASP.NET]

[Shameless Author plug]
Professional VSTO.NET - Wrox/Wiley
The O.W.C. Black Book with .NET
www.lulu.com/owc, Amazon
Blog: http://www.msmvps.com/blogs/alvin
-------------------------------------------------------

ODAN said:
We are testing a ASP.NET application in Visual Studion 2003 and written
in
C#. One of the pages that register new users on this application fails
to
redirect to another page when the button is clicked. On the page there is
a
button that has been code to save to database and also redirect to the
login
page. When you fill out the form and click on this page, it saves the
data
into the database but it does nothing after that, it just sits there on
the
same page. We checked everytihng in the code and the web.config file. The
web applicaiton is working good on the development workstation (Win XP),
but
not working on the server running Windows Server 2003 IIS6. Please help?
Any
ideas?


try

{

if(Session["RegistrantID"]!=null)

{

divusername.Visible=false;

string registrantId=Session["RegistrantID"].ToString;

string userName=Session["username"].ToString();

if(WRTSPublic.DataAccess.DataAccess.UpdateRegistrantDetails(registrantId,userName,RegistantObj,dsCompenOrg,selectedCountiesArr))

{

Response.Redirect(TrainingURL,false);

}

}

else

{

if(WRTSPublic.DataAccess.DataAccess.InsertRegistrantDetails(RegistantObj,dsCompenOrg,selectedCountiesArr))

{

Response.Redirect(IntroductionURL,false);

}

}

}

catch(Exception ex)

{

ExceptionCatch.RegisterLog(ex.Message);

}

}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,817
Latest member
DicWeils

Latest Threads

Top