Order of loading pages...

S

Seth Broomer

Hi, i have a .aspx Page, inside that page is a web user control.

The user control is basically a login control.

if the user is logged in the page shows one thing.
if the user isn't logged in it shows something else (basically telling them
to login)


but i have noticed that when the user logs in through the control, first the
page_load event on the .aspx page is ran,
then the onclick event for the login image event on the web control is
ran...but because of that order, now i need to access the page_load event on
the .aspx page again... is there a way to reference that .aspx page?

thanks
 
S

Sam

If your page class is called Default I believe you can go
((Default)this.Page) and access any properties. Someone else here can
back me up on this.

But there is no way to get back to PageLoad after OnClick of your user
control. See this page for details:
http://aspalliance.com/articleViewer.aspx?aId=134&pId=

However, you should be able set any properties of the page or the user
control in the OnClick event of the user control.

What are you trying to do exactly?

-Sam
 
S

Seth Broomer

Sorry for taking so long.

I have a login user control on the page.
let say they come to a chat page, and they have a message that says they
first have to login before they can chat. on the left hand side is the login
control where they put their username and password.

they then log in, and the chat page allows them to chat(by basically loading
up a different part of the page)

but i have a bunch of lil' pages like this, so that i can't specifically say
check this page....so i have to reference the parent page. however when i
try and do that, it doesn't like it...

ugh!
 

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,228
Members
46,818
Latest member
SapanaCarpetStudio

Latest Threads

Top