473,511 Members | 13,105 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Differences between running in VS and calling an ASP.Net page froma browser

I have developed a little ASP.Net application that works fine when
started in the VS IDE. However when I call it from our "home" page it
doesn't work.

The page_load event handlers of two pages set a cookie for their
respective pages. Buttons on the pages check for the existence of their
cookie (in client-side onclick scripts) before proceeding. It has be
client-side for reasons I'll not bore you with unless you're really
interested.

It all works beautifully in the IDE, but the cookies are always empty
when retrieved from script in a page called in the "live" environment
(i.e. called from another page via an HTML link). They have their
expected values (of course) when retrieved in the same script where the
application has been started from the IDE - even when the page is not
the start page.

Is it something to do with being called from HTML links? Does the
page_load event not happen when pages are loaded in this way rather than
being "open"ed from code?

Thanks in advance

Peter

Nov 17 '05 #1
2 1216
Peter,

Let us see some of the code.

--
S. Justin Gengo
Web Developer / Programmer

Free Code Library At:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
"Peter Bradley" <pb******@uwic.ac.uk> wrote in message
news:bf*********@news.swman.net.uk...
I have developed a little ASP.Net application that works fine when
started in the VS IDE. However when I call it from our "home" page it
doesn't work.

The page_load event handlers of two pages set a cookie for their
respective pages. Buttons on the pages check for the existence of their
cookie (in client-side onclick scripts) before proceeding. It has be
client-side for reasons I'll not bore you with unless you're really
interested.

It all works beautifully in the IDE, but the cookies are always empty
when retrieved from script in a page called in the "live" environment
(i.e. called from another page via an HTML link). They have their
expected values (of course) when retrieved in the same script where the
application has been started from the IDE - even when the page is not
the start page.

Is it something to do with being called from HTML links? Does the
page_load event not happen when pages are loaded in this way rather than
being "open"ed from code?

Thanks in advance

Peter

Nov 17 '05 #2
Is your ASP.Net app in the same domain as your "home" page? Cookies are
domain-specific.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
http://www.takempis.com
Big things are made up of
lots of little things.

"Peter Bradley" <pb******@uwic.ac.uk> wrote in message
news:bf*********@news.swman.net.uk...
I have developed a little ASP.Net application that works fine when
started in the VS IDE. However when I call it from our "home" page it
doesn't work.

The page_load event handlers of two pages set a cookie for their
respective pages. Buttons on the pages check for the existence of their
cookie (in client-side onclick scripts) before proceeding. It has be
client-side for reasons I'll not bore you with unless you're really
interested.

It all works beautifully in the IDE, but the cookies are always empty
when retrieved from script in a page called in the "live" environment
(i.e. called from another page via an HTML link). They have their
expected values (of course) when retrieved in the same script where the
application has been started from the IDE - even when the page is not
the start page.

Is it something to do with being called from HTML links? Does the
page_load event not happen when pages are loaded in this way rather than
being "open"ed from code?

Thanks in advance

Peter

Nov 17 '05 #3

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

Similar topics

18
12637
by: Simula | last post by:
I am developing an HTML javascript application and I want to preserve state in a way that can be book-marked. I chose HTML anchors as a means of preserving state. When the application changes...
5
3360
by: PontiMax | last post by:
Hi, when I press the OK button of my dialog box a long-running task is initiated. Therefore I would like to make visible a div section right after clicking the button where a user-friendly...
16
3156
by: MR | last post by:
my soap messages to a remote site are failing. as far as i can tell the only differences between what my SOAP message looks liek and what they want are in the SOAP envelope SInce they don't have a...
14
23110
by: lmttag | last post by:
Hello. We're developing an ASP.NET 2.0 (C#) application and we're trying to AJAX-enable it. We're having problem with a page not showing the page while a long-running process is executing. So,...
0
7245
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7356
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7427
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7512
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5671
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3227
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3214
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1577
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
449
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.