Datagrid embedded textbox text fill on postback

P

Peppie

Hi,

I have dropdown control on my form and after the onchange event I
reload a datagrid and fill a textbox embedded in a cell with the text
from the invisible next column. Unfortunately the text will not fill
on postback. The data is present in the column next to the template
column but the textbox will not be filled by the code beneath. I cast
the embedded control to a textbox and I am able to change all other
properties but the text. Any idea?

TextBox
txt=(TextBox)e.Item.Cells[General.GetCellValue(dgrTexts,language.Description)].Controls[0];
if(e.Item.Cells[General.GetCellValue(dgrTexts,language.ID.ToString())].Text
!="&nbsp";
txt.Text=e.Item.Cells[General.GetCellValue(dgrTexts,language.ID.ToString())].Text;
else txt.Text="";


Thanks, Peppie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,342
Messages
2,571,416
Members
48,794
Latest member
massivestack

Latest Threads

Top