Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

Hello everybody:

I have a WebUserControl embedded into a Web Form (I�m using C# .net).

When I load Web Form I need to set the cursor into a Textbox that is into WebUserControl.

In <body> of Web Form I have:

<body bgColor=�#ccfff MS_POSITIONING=�GridLayout� onload=�document.WUCDatos.TextBox2.focus(); �>

Where WUCDatos is form id of WebUserControl and TextBox2 is the Text Box into WebUserControl.

But this code doesn�t work.

I�ll appreciate your help.

A.L.

Posted

Thanks you very much for your suggestion, finally the way I achieved this was <body bgColor=�#ccfff MS_POSITIONING=�GridLayout� onload=�document.forms[0].WUCDatos1_TextBox2.focus();�>

If you have more than 1 WebUserControl change [0] for [1] and thus�

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...