Hi,
I am new to this forum, Please tell the solution to this issue?
I am using Ultrawebgrid , directly it have one datasource value. Can i change the datasource at runtime, ?
1. Ultrawebgrid have a lot of controls, i want get the value of the particular row..?For Example : one column have webnumeric control , i want to
get the value of the particular row value...
Each column have EditcontrolId, how can i assign the value to the controls?
With Regards,
Raji
Thank u so much for quick response.
Code :
When i click the button control :[ Button click event] : this code will execute and update in cell.if some other events occured, then the cell value is empty. how can i solve this issue.
int dcnt = grdBIDResponseItemLinkLDLink.DisplayLayout.Rows.Count; for (int j = 0; j < dcnt; j++) { double pts = Convert.ToDouble(grdBIDResponseItemLinkLDLink.DisplayLayout.Rows[j].Cells.FromKey("PurchaseDiscountPercentage").Value);
double gamt = Convert.ToDouble(grdBIDResponseItemLinkLDLink.DisplayLayout.Rows[j].Cells.FromKey("GrossAmount").Value); double tot = gamt* pts ; grdBIDResponseItemLinkLDLink.DisplayLayout.Rows[j].Cells.FromKey("BIDLineDiscountLinkAmount").Value = tot; }
i am using ultrawebgrid, i have three columns, each column have webnumeric control,
i have to give value to the 2 columns, i click the button[.Net webcontrol][button click event], that time calculation will perform and assign the value to the third column,
after perform this calculation, i have to calculate the some values in other events, that time the page is refreshed and 3rd column value is not shown .
rajalakshmi2008 said: If i assign the value to the cell, after postback the data is not shown in that cell.
If i assign the value to the cell, after postback the data is not shown in that cell.
In what event handler are you doing this?
It often helps if you post any applicable markup and code.
Thanks for your quick respone,
structure is, col1,col2,result [this is the ultrawebgrid column]
col1*col2 = result.
10 10 100
when i click the button the calculation will updated in the cell,after clicking some event [postback]. values not shown in the cell
pl tell me how to solve this issue?
1. Can i change the datasource at runtime, ?
Yes, you can, But you have to take care of column names that are already assigned. (or) You can change the grid layout dynamically based on requirements.
2. i want get the value of the particular row..?
row.Cells.FromKey(ColumnName).Text
row.Cells.FromKey(ColumnName).Value
3. Each column have EditcontrolId, how can i assign the value to the controls?
You assign the value to columns using following syntax. Editor controls also renders the same data.
ColumnName.BaseColumnName = "DataSourceColumnName";
In case If you are doing any kind of customization you can handle row initializa event.
Hope this will help you.
Thanks,
Kedar.