Last post Aug 02, 2007 02:02 PM by suprej
Aug 02, 2007 01:51 PM|loydall|LINK
I want to call this function x amount of times passing a different value to each time based on the contents of a database.
I'm obviously doing my database call from my code-behind and returning a load of results.
This needs to be done on the page Load.
Aug 02, 2007 02:01 PM|somnathmali|LINK
To which control you are bindind the data...
Suppose you are using the DataGrid. Then you can use ItemDataBound event.
- In this Event is if e.ItemType is Item then ..
- Same , You can get the valueToSend from any Hidden control in the DataGrid ( suppse ID )
- Set the ctrl.Attributes.Add( "obclick" , "functionName('" + valueToSend + "' )");
Aug 02, 2007 02:02 PM|justKiran|LINK
You can do the same as follows,
in your case, you just have to write inside loop.
Aug 02, 2007 02:02 PM|suprej|LINK
This shows how to register javscript scripts from the code behind.
Please let us know whether you have any other method in mind.