Alex wrote:
> I'm using a DataGrid with several bound columns. However for one column I
> had to use a ItemTemplate with a asp:hyperlink in it.
> How can I switch the hyperlink column into the edit mode in the datagrid
> event handler?
You need to provide an EditItemTemplate in the TemplateColumn.
<asp:TemplateColumn>
<ItemTemplate>
<asp:HyperLink ... />
</ItemTEmplate>
<EditItemTemplate>
<asp:TextBox runat="Server" id="txtLinkEdit" Text='<%#
DataBinder.Eval(Container.DataItem, "hyperlinkFieldName")' />
</EditItemTemplate>
</asp:TemplateColumn>
To learn how to read the value of the edited TemplateColumn
programmatically, see:
http://datawebcontrols.com/faqs/Prog...Contents.shtml
Happy Programming!
--
Scott Mitchell
http://www.4GuysFromRolla.com
http://www.ASPFAQs.com
http://www.ASPMessageboard.com
* When you think ASP, think 4GuysFromRolla.com!