Click here to Skip to main content
16,010,392 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: designs Pin
Brian Delahunty11-Oct-02 5:13
Brian Delahunty11-Oct-02 5:13 
GeneralRe: designs Pin
Paul Riley11-Oct-02 9:29
Paul Riley11-Oct-02 9:29 
GeneralRe: designs Pin
Brian Delahunty12-Oct-02 0:23
Brian Delahunty12-Oct-02 0:23 
GeneralRe: designs Pin
Ray Cassick10-Oct-02 7:51
Ray Cassick10-Oct-02 7:51 
GeneralRe: designs Pin
David Flores10-Oct-02 7:56
David Flores10-Oct-02 7:56 
GeneralRe: designs Pin
Ray Cassick10-Oct-02 8:37
Ray Cassick10-Oct-02 8:37 
GeneralRe: designs Pin
bigreddog15-Oct-02 1:46
bigreddog15-Oct-02 1:46 
GeneralGetting text of textbox in datagrid Pin
Mazdak10-Oct-02 5:07
Mazdak10-Oct-02 5:07 
I have a datagrid with this definition:

<asp:DataGrid id="CatGrid" runat="server" CssClass="Grid_General" HeaderStyle-CssClass="Grid_Header" ItemStyle-CssClass="Grid_Item" AlternatingItemStyle-CssClass="Grid_AlternatingItem" AllowSorting="True" AutoGenerateColumns="False" DataKeyField="CategoryID" OnEditCommand="CatGrid_Edit" OnCancelCommand="CatGrid_CancelEdit" OnUpdateCommand="CatGrid_Update" OnDeleteCommand="CatGrid_Delete" OnSortCommand="CatGrid_Sort" Width="100%">
<Columns>
<asp:EditCommandColumn ItemStyle-Width="25px" EditText="<img border=0 Alt='Edit this category' src=./Images/Edit.gif>" CancelText="<img border=0 src=./Images/Cancel.gif>" UpdateText="<img border=0 src=./Images/OK.gif>" />
<asp:ButtonColumn ItemStyle-Width="25px" Text="<img border=0 Alt='Delete this category' src=./Images/Delete.gif>" CommandName="delete" />
<asp:BoundColumn HeaderText="ID" HeaderStyle-Font-Bold="True" ItemStyle-Width="30px" DataField="CategoryID" ReadOnly="True" SortExpression="CategoryID" />
<asp:TemplateColumn HeaderText="Name" HeaderStyle-Font-Bold="True" SortExpression="Name" ItemStyle-Width="150px">
<ItemTemplate>
<asp:Label runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Name") %>' ID="Label1" />
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox ID="EditCatName" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "Name") %>' CssClass="TextBox" Width="150px" />
<asp:RequiredFieldValidator Id="ValidateEditName" runat="server" ControlToValidate="EditCatName" Display="dynamic">* Name is required</asp:RequiredFieldValidator>
</EditItemTemplate>
</asp:TemplateColumn>
.
.
.
</Columns>
</asp:DataGrid>


When user press on first field of first column,that row goes in edited mode and text box appear for that
row,then after he/she change the text there DataGrid1_Update event occur,in that event I put this code:

string strCol2 = ((TextBox)e.Item.FindControl("EditCatName")).Text;


but when I debug the program,the text is not updated and show the previous text.Any idea?


<html><b><FONT face="Lucida Handwriting, Cursive">Mazy</FONT></b></html>

<small><b>"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"</b>Kryptonite-3 Doors Down </small>

GeneralRe: Getting text of textbox in datagrid Pin
David Flores10-Oct-02 7:27
David Flores10-Oct-02 7:27 
GeneralRe: Getting text of textbox in datagrid Pin
Mazdak10-Oct-02 10:00
Mazdak10-Oct-02 10:00 
GeneralTab Control using Javascript Pin
Hitu9-Oct-02 23:30
Hitu9-Oct-02 23:30 
GeneralRe: Tab Control using Javascript Pin
Ray Cassick10-Oct-02 5:26
Ray Cassick10-Oct-02 5:26 
QuestionHow to display messagebox on client machine in asp.net ? Pin
AJPrayag9-Oct-02 18:42
AJPrayag9-Oct-02 18:42 
AnswerRe: How to display messagebox on client machine in asp.net ? Pin
Paul Watson9-Oct-02 23:08
sitebuilderPaul Watson9-Oct-02 23:08 
GeneralRe: How to display messagebox on client machine in asp.net ? Pin
David Flores10-Oct-02 7:48
David Flores10-Oct-02 7:48 
GeneralRe: How to display messagebox on client machine in asp.net ? Pin
Ray Cassick10-Oct-02 8:56
Ray Cassick10-Oct-02 8:56 
GeneralRe: How to display messagebox on client machine in asp.net ? Pin
Paul Watson10-Oct-02 20:50
sitebuilderPaul Watson10-Oct-02 20:50 
AnswerRe: How to display messagebox on client machine in asp.net ? Pin
Pradhip10-Oct-02 11:56
Pradhip10-Oct-02 11:56 
GeneralHttp controls and .Net Pin
Anonymous9-Oct-02 17:55
Anonymous9-Oct-02 17:55 
GeneralRe: Http controls and .Net Pin
Anders Munk10-Oct-02 3:42
Anders Munk10-Oct-02 3:42 
GeneralRe: Http controls and .Net Pin
Anonymous10-Oct-02 12:03
Anonymous10-Oct-02 12:03 
Generalsetting value field of input - file object Pin
bjnst69-Oct-02 11:09
bjnst69-Oct-02 11:09 
GeneralFileSystemObject, ASP and Windows NT authentication.... Pin
goddess_spanky9-Oct-02 8:02
goddess_spanky9-Oct-02 8:02 
GeneralRe: FileSystemObject, ASP and Windows NT authentication.... Pin
Daniel Turini9-Oct-02 8:35
Daniel Turini9-Oct-02 8:35 
GeneralRe: FileSystemObject, ASP and Windows NT authentication.... Pin
goddess_spanky9-Oct-02 8:55
goddess_spanky9-Oct-02 8:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.