CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums




Can Reply:  No Members Can Edit: No Online: Yes
Zone: > NEWSGROUP > Asp.Net Forum > general_asp.net.master_pages_themes_and_navigation_controls Tags:
Item Type: NewsGroup Date Entered: 11/27/2007 2:23:39 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
NR
XPoints: N/A Replies: 3 Views: 63 Favorited: 0 Favorite
4 Items, 1 Pages 1 |< << Go >> >|
jorgeolimpia
Asp.Net User
Set focus in an object with Master Pages and AJAX Control Toolkit11/27/2007 2:23:39 PM

0

Hello guys!

I'm trying to set focus in an object after execute some actions in my form but I'm not having sucess!

This actions are basically enable/disable buttons and textboxes.

On my web page I'm using Master Pages and AJAX Control Toolkit, and I tried to use this methods with no sucess: 

Me.TextBox1.Focus()

Me.Page.Forms.SetFocus(Me.TextBox1.ClientID)

I tried to use a javascript with object ID but it doesn't work too.

Any ideas?

Thanks a lot!

Jorge Olimpia

Joël Hébert
Asp.Net User
Re: Set focus in an object with Master Pages and AJAX Control Toolkit11/27/2007 3:24:33 PM

0

 

use uniqueid instead of clientid
Jo?l H?bert

ASP.NET Consultant
Opulent ASP Development Inc.
www.opulentasp.com
Ottawa,Canada
jorgeolimpia
Asp.Net User
Re: Set focus in an object with Master Pages and AJAX Control Toolkit11/27/2007 8:22:43 PM

0

Hi Joel.

Unhapply the code doesn't work too.

I tried to do this: Me.Page.SetFocus(Me.DropDownList1.UniqueID) or Me.Page.SetFocus(Me.TextBox1.UniqueID)

The UniqueID is correct now, but the focus doesn't work...

Is it necessary to enable some property on my page?

Thanks,

Jorge Olimpia

Amanda Wang - M
Asp.Net User
Re: Set focus in an object with Master Pages and AJAX Control Toolkit11/29/2007 8:32:06 AM

0

Hi,

Base on your description, you want to set the form's focus on the textbox1, right?

You can try to do like this: Me.SetFocus(Me.TextBox1), this code can works on the page with master page on my machine.

The SetFocus method's param is a control object, but Me.TextBox1.ClientID is a string.

 

Hope it helps.


Please remember to mark the replies as answers if they help and unmark them if they provide no help.


Yours sincerely,
Amanda Wang
Microsoft Online Community Support
4 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
PROFESSIONAL ASP.NET 3.5 IN C# AND VB Authors: Bill Evjen, Scott Hanselman, Devin Rader, Pages: 1728, Published: 2008

Web:
Set focus in an object with Master Pages and AJAX Control Toolkit ... I'm trying to set focus in an object after execute some actions in my ... On my web page I'm using Master Pages and AJAX Control Toolkit, ...
AJAX Control Toolkit - View Issue You have to remove focus from the textbox and then set focus back to the textbox to get the extender ... protected void Page_Load(object sender, EventArgs e) ... I have a master page and the autoextender is working in the content page. ...
Textbox Set Focus on Load while using AJAX Controls on Page - Asp ... Apr 23, 2009 ... normal way of making set Focus to textbox controls won't work. Solution to this Problem: protected void Page_Load(object sender, EventArgs e) { AjaxControlToolkit.Utility.SetFocusOnLoad(txtEmailId); } Where, txtEmailId is control name. In every other case where you are not using AJAX Control on Page ...
How to I set focus to a TextBox inside a Panel which is inside an ... Apr 23, 2008 ... NET (VS2005) and needed some help setting focus to a TextBox which ... UI" TagPrefix="asp" %> <%@ Register Assembly="AjaxControlToolkit" Namespace=" AjaxControlToolkit" ... Sub SetTxtFocus(ByVal sender As Object, ByVal e As System. .... My ScriptManager is on Master Page. The Control I would like to ...
SetFocus to a Textbox on PageLoad with MasterPage, TabPanel ... This gives an error in indicating object required. ... <%@ Register Assembly=" AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" % ... That should make your focus go to your textbox on page load and also when the tab is clicked .... Master.FindControl("i_sm")).SetFocus((TextBox)i_fv. ...







control within master page gets "does not exist in the current context"

disable wizard navigation button in templatedwizardstep

ms crm / outlook web. statically positioned, dynamic menu selection. how is this done?

theme repository?

menu control w/web.sitemap

headerstyle problems

i've been looking at this for too long - menu issue

creating a expandable menu with treeview

menu problems with appearing under master page content

switching master page css theme programmatically

treeview target=_blank

compiler error message: bc30456: 'theme' is not a member of 'asp.index_aspx'.

how to programm dynamic navigation with submenus like in cms. is there a webcontrol for it?

localize navigationurl of asp:hyperlink

asp.net menu control

please help...

master page cart update

getelementbyid gets wrong id?

capturing button_click event from master page

viewstate not saved on master page

loading items in a menu instance from an xml file

problem with treeview expand for current page

using web.sitemap to generate "next" and "previous" links

specify which sitemap to take for the sitemappath

sitemap - cannot get it to display

are masterpages stable?

dynamically load website.map file based on active directory group

problem with treeview's checkednodes not being set correctly

user can decide beteween two different styles (css .skin etc)

hi, i have a problem with stylesheets, can you please help me?

   
  Privacy | Contact Us
All Times Are GMT