Aug 02, 2012, 6:59 AM
[CLOSED] How To Focus TextArea
Hi,
can help to focus the textarea, so the cursor will automatically in the text area?
Eventhou i already use autofocus property, still unable to focus.
thanks
aspx
can help to focus the textarea, so the cursor will automatically in the text area?
Eventhou i already use autofocus property, still unable to focus.
thanks
aspx
<ext:ResourceManager ID="ResourceManager1" runat="server" />
<div>
<ext:Button ID="Button_Other_ReportList_Tag" runat="server" Text="show" >
<Listeners>
<Click Handler="Ext.net.DirectMethods.ShowWindow();" />
</Listeners>
</ext:Button>
<ext:Window ID="winResultTaggingComment" runat="server" Hidden="true" Modal="true" Border="false" Closable="true" Width="500" Height="500" Title="Comments History">
</ext:Window>
</div>
aspx.cs protected void Page_Load(object sender, EventArgs e)
{
UserControl uc1 = (UserControl)this.LoadControl("UserControl.ascx");
winResultTaggingComment.ContentControls.Add(uc1);
}
[Ext.Net.DirectMethod]
public void ShowWindow()
{
this.winResultTaggingComment.Show();
}
ascx<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="UserControl.ascx.cs" Inherits="ExtNetTest.UserControl" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<ext:Panel ID="PanelHorizontalLine_ResultTagging" runat="server" Height="5">
<Content>
blablabla
</Content>
</ext:Panel>
<ext:Panel ID="PanelComment_ResultTaggingComment" runat="server" LabelAlign="Top" Layout="Form" Height="100">
<Items>
<ext:TextArea ID="TextArea_ResultTaggingComment" runat="server" FieldLabel="Comment(s)" AnchorHorizontal="100%" Height="75" AllowBlank="false" InvalidClass="x" AutoFocus="true" AutoFocusDelay="10">
</ext:TextArea>
</Items>
</ext:Panel>
Last edited by Daniil; Aug 07, 2012 at 4:55 AM.
Reason: [CLOSED]