I have an asp table being built dynamically inside an ajax update panel.
I have a text field, number, date and some fields using the webmaskedit. The text field and the mask edit fields are firing the onblur events fine but I cannot get the webdatechooser or the webnumeric edit to fire their events.
Does anyone have any suggestions as to what might be going on ?
Warm regards
Peter
Sorry Peter, no idea on this one. Sounds like an issue for our support team to handle. (http://es.infragistics.com/gethelp)
-Tony
Hi Tony,
thanks for thinking about this at least !
I have had quite a lot of discussions with support around this area (to no avail), so I was hopeing someone could put a different slant on the problem and go "hey presto" which doesnt look like its going to be.
For completness this issue has three aspects but all are to do with using an ajax update panel under webtabs. This is so that I an populate one (or more) tab with a "table" of the data that relates to the value from a ddl. Without going into the specifics of the application this comes up in the following manners
1) the table needs to be created so that onblur events can be added to the IG fields as they are added to the "table". In this case I have a mix of fields being added which have text, igdate, ignumber or igmask types. The event for the standard text field fires no problem - but the IG fields only fire in errrmmm... an inconsistent manner... some fire some dont.
2) I need to use an ID field to find the control to get the value. This was the alternate strategy to using the onblur event - however I have been told that persistence isnt supported :(
3) Create the table using a c# string build and then replace it in the div. I have used this well for lots of other areas but not using IG controls - I cannot find any guidance in how to use the IG controls under this circumstance.
As I hope you can see I have tried a lot of variations to get to the same result and in each case I come up against the persistence issue of IG controls under a webtab. In that case I have tried to use string build (div replacement) route... but Im stuck!
I have turned my attention to webschedules for now as I dont want to take out IG controls from the "table" as they are theway forward - but without an solution I may be forced to take out the IG controls from this area and use JS to validate the fields - which isnt the cool look I was hoping for :(
Maybe you or one of the community could suggest an alternate route to getting this ?
Any suggestions are definitely worth a beer or two!
Best regards
Peter,
Dynamic content in ASP.NET is not a fun task. The root problem is that ASP.NET creates this whole page framework along with viewstate, and it has a certain expectation that the control tree will look exactly the same before and after a postback. Rather than constructing the table using a string builder, can you use an actual Table web control? Also, replacements in ASP.NET should always be done using a placeholder control.
It might be best to start from the beginning - what is the requirement of the page? How does the webtab fit in? And can you be flexible with the 'table'?
Also, when you add the blur events, are you adding them using the client-side events? If onblur isn't firing it means one of two things - the client-side object model was never 'created' for the control or the events got disconnected somehow. I'm guessing when the elements are being 'moved' the events are somehow being dropped. Adding events manually may not be a very straight forward task either. The control's do a lot to filter out the events and make onblur fire when it's supposed to. I think the key is going to be - getting the editor controls into your 'table' through the ASP.NET control tree.