C# GridView dynamically built columns with textboxes ontextchanged
- by tnriverfish
My page is a bulk order form that has many products and various size options.
I've got a gridview that has a 3 static columns with labels.
There are then some dynamically built columns.
Each of the dynamically built columns have a textbox in them.
The textbox is for quantity.
Trying to either update the server with the quantity entered each time a textbox is changed (possibly ontextchanged event) or loop though each of the rows column by column and gather all the items that have a quantity and process those items and their quantities all at once (via button onclick).
If I put the process that builds the GridView behind a if(!Page.IsPostBack) then the when a textchanged event fires the gridview only gets the static fields and the dynamic ones are gone.
If I remove the if(!Page.IsPostBack) the process to gather and build the page is too heavy on processing and takes too long to render the page again.
Some advice would be appreciated.
Thanks