|
Thanks for your reply.
The website I am working in refreshes every second to keep the data up to date. Clicking the control does a AJAX postback and that part is working fine. The problem is that I want to change the control settings in the server due to some server events. Now to force the control rendering independently of all the other controls Invalidate essentially call Update() on the UpdatePanel associated with the control. For some reason the Render method of the control does not get called when the Update is called on the UpdatePanel.
googling this suggests that I need to implement ITemplate, add the control to it and replace the ContentTemplate with it. But it seems this technique is not working.
I hope I am clear enough in what I am looking for.
Thanks,
Live Life King Size
|
|
|
|
|
you want the server to force a control to update ? That can't happen. AJAX doesn't mean the server can talk to the client.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Yes it can happen. If the trigger of the UpdatePanel is set to conditional then calling Update() on the UpdatePanel will do an update. Like I was mentioning that I am doing a postback every 1 second and checking for changes. This ensures the Server forcing a client update. Only if somethings happens in the server, a certain UpdatePanel gets updated.
|
|
|
|
|
Yes, you can force it to call every second, but your server can only respond to those calls, it can't make a call to a webpage. Every AJAX call can change the controls on the page, in fact, you can use js to do that any time you like.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Yes thats true.
So I think in this hussle we forgot about the original problem. How to add a control to the UpdatePanel dynamically and force the call to UpdatePanel.Update() to call Render(HtmlWriter writer) on the child controls.
Thanks
|
|
|
|
|
I'm not sure I understood the question. You're saying if you add a control dynamically, it doesn't get drawn ? Or it doesn't get redrawn ? Is the real issue that the control loses it's state when it gets added like that ?
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
I am saying that what a control is dynamically added it gets drawn first time correctly but in the subsequent postbacks it does not get redrawn.
What I am trying to achieve here is that if in one of the postbacks(the 1 sec postbacks) if a control has to be redrawn(new HTML tags to be generated) it should be self sufficient and should not rely on the fact that it has to be placed inside some other UpdatePanel.
On the first postback everything works fine but if in a subsequent the server tries to change the state of the control ( e.g. add a div tag with some content etc) in the Render method, it does not happen.
Thanks
|
|
|
|
|
Thanks for your help.
I have resolved the issue.
|
|
|
|
|
I am using Menu control in association with MultiView/Views. When this menu item is clicked where I have the CheckBoxList - it doesn't select the CheckBoxes from the info from my database, requires a second click.
I am not calling DataBound for some other reason. If I used databound in Page_Load, it would display fine.
Any idea how I can fix it?
Thanks.
|
|
|
|
|
Found a reasonable solution. Thanks.
|
|
|
|
|
What is your solution?
ma tju
Pengaturcara Perisian
Subang Jaya,Selangor, Malaysia
Ring Master SB MVP 2008
Subang Jaya MOP (Otai)
|
|
|
|
|
1. In Page_Load (If (!Page.IsPostBack)), get the info from the database, select the CheckBoxes that matches the criteria based on that info, and DataBind().
2) In MultiView_ActiveIndexChanged event handler, get the info from the database, select the CheckBoxes that matches the criteria based on that info.
3) Use a Save button, and in the Button_Click event handler, first Delete info from the table for the ID I am working with, then Insert values for that ID and each of the CheckBoxes that are currently selected.
4) Don't try to do anything in the SelectedIndexChanged for the CheckBoxList (which is a logical thing to try), because here, you don't know which Box is clicked as the sender is the List, not any individual CheckBox. If you have any Label to display messages, you can just clear the label here.
Thats it.
Thanks.
|
|
|
|
|
Hi,
How to save the Customer Information and where to save it at the time of the Installation of the project using web application in web setup project
How to Handle The Serial Number Key in Customer Information ? and how to Add my own key and how to maintain it
Thanks
Shavil
|
|
|
|
|
Hi,
After Installing the Project, I want to Create the Desktop Shortcut Icon on Desktop,in Program files and in windows startup.
please send the Code or Link based on the "Web Application" of web setup project only.in windows application its no need.
Thanks
Shavil
|
|
|
|
|
can anyone guide me that i have a update panel & i want to refresh updatepanel using javascript
when i use __dopostback();
it refreshes whole page.how to refresh perticular update pannel instead of whole full postback.
umerumerumer
|
|
|
|
|
|
You'll have to use async trigger for this purpose.
Check it [^]">
Cheers!!
Brij
|
|
|
|
|
What is meant by Merge Module?
Balasubramanian K.
|
|
|
|
|
BalasubramanianK wrote: What is meant by Merge Module?
Means , Merging Two Different Module !! .
In what prospect you are asking this ? Is it anything related with asp.net ?
if yes, then just clarify your query in details .
Thanks !!
cheers,
Abhijit
|
|
|
|
|
I've heard this. We build application with crystal rpt and deploy in the server. In server, we dont want to install cr. For that purpose, If we build the asp.net application with merge module, we can avoid the problem. Thats why I put my qtn here
Balasubramanian K.
|
|
|
|
|
You might want to take a look at this[^]. Or just scroll down slightly...
|
|
|
|
|
cheers,
Abhijit
|
|
|
|
|
very good replies. Thank you my dear friends
Balasubramanian K.
|
|
|
|
|
http://msdn.microsoft.com/en-us/library/z6z02ts5.aspx[^]">
Balasubramanian K.
|
|
|
|
|
I open my crystal report, which is in vs 2005, in my same page. I want to open the report in another page. What to do? Tnx in adv.
Balasubramanian K.
|
|
|
|