Hi,
I am playing around with an existing intranet application. This web application is a query tool that does many different types of queries depending on the selections made by the user. At present what ever type of query the user selects will cause the page to redirect to the relevant page for that query. It is ok and there are no issues. Its just looks a bit naff having the page refresh and flicker everytime the query type changes. Also get more unmaintainable as time goes on.
I have added a user control for the user selection and used some ajax in it and it looks much smoother. What I am now trying to do is have just one web page and dynamically add the appropriate user control/s.
Here is where I am up to.
I have an event on the page that the user selection control can raise. From this I can call a populate method in the appropriate user control that will show that particular type of search. Here is the code that does this:
The control does not show. I have stepped through on the debugger, it goes through all of the code with no errors, but still results in not showing.
The control still fails to show, can somebody please tell me what I am doing wrong?
Cheers, Dave.
I am playing around with an existing intranet application. This web application is a query tool that does many different types of queries depending on the selections made by the user. At present what ever type of query the user selects will cause the page to redirect to the relevant page for that query. It is ok and there are no issues. Its just looks a bit naff having the page refresh and flicker everytime the query type changes. Also get more unmaintainable as time goes on.
I have added a user control for the user selection and used some ajax in it and it looks much smoother. What I am now trying to do is have just one web page and dynamically add the appropriate user control/s.
Here is where I am up to.
I have an event on the page that the user selection control can raise. From this I can call a populate method in the appropriate user control that will show that particular type of search. Here is the code that does this:
Code:
userctrl.Populate(Field, Value)
Dim ctrl As New Control
ctrl = LoadControl("UserControls/userctrl.ascx")
Me.Controls.Add(ctrl)
The control still fails to show, can somebody please tell me what I am doing wrong?
Cheers, Dave.
Last edited by a moderator: