Weird Problem in Asp.Net 2.0 App

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all , and lets Get to the point :

To create the Problem i have ,please do this :

info : ASP.net 1.1,

1 - Create a Sub that Contains a code to creat a control Like a dropdown
List and Fill It with dummy Data, Please Note that u need a contaier to
put the control in "Place Holer ....."!

2 -Put this sub in the sub in the page Load event


3 - Now Creat another Sub and code the Script to find the Control u
created By the First Sub and , and use it in a button Named "FindMe" i used
"me.findControl(blablabal.......".and get the Control value and show it where
ever u Like

3 - So Far so good No Errors , NOW Rem the Sub in the Page Load Event , and
put another Button , and use the Sub that Creats the
Control and name it "CreatMe", note that we are not using the sub in the
Load event any More , run the Page Click on Creat Me Button Yepeee No
Prob,the Control is on the Page Nice and neeeet. and I can See it ;ok Now
click on the Find Me Wops Where did it GO "DA**" and an error booooom on the
Page,

So any Idea.whats Going On is it a bug or whats wrong.
 
Morad,

I am not sure that I understand you. However because that a page is
stateless, is there no information anymore when there is a post back.

Therefore you have to recreate all data that should be in the page,
including dynamicly created controls etc. This has nothing to do with a bug,
you find this back in all other kinds of behaviour.

I hope this gives an idea.

Cor
 
Back
Top