473,396 Members | 1,975 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

How does one set focus to an IP Address control on a Property Page

I am unable to set focus to an IP address control residing on a Property Page, following validation of the IP when the user hits the 'Finish' button on the Property Sheet.

I've unsuccessfully tried to use:
CWnd::SetFocus
CIPAddrCtrl::SetFieldFocus
WM_SETFOCUS sent via SendDlgItemMessage (this approach
helped set focus to edit and combo boxes, but not an ip address control).
Also tried sending IPM_SETFOCUS... but this didn't work.

If the IP address is set to 0.0.0.0, I fail the validation; pop up a message box for the user, and after user hits ok, I'm back to the wizard, but there's no input focus on the IP address control (no caret blinking).

Any help is much appreciated.
Nov 17 '05 #1
1 1468
Env: VC++ 6.0 on Win XP.

"gotFun" wrote:
I am unable to set focus to an IP address control residing on a Property Page, following validation of the IP when the user hits the 'Finish' button on the Property Sheet.

I've unsuccessfully tried to use:
CWnd::SetFocus
CIPAddrCtrl::SetFieldFocus
WM_SETFOCUS sent via SendDlgItemMessage (this approach
helped set focus to edit and combo boxes, but not an ip address control).
Also tried sending IPM_SETFOCUS... but this didn't work.

If the IP address is set to 0.0.0.0, I fail the validation; pop up a message box for the user, and after user hits ok, I'm back to the wizard, but there's no input focus on the IP address control (no caret blinking).

Any help is much appreciated.

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: starbuck | last post by:
We have some fields with AutoPostBack set to true and when user tabs to the next field the screen re-calculates correctly however we also lose which control/text box had focus when the user tabbed....
1
by: Mad Scientist Jr | last post by:
I have a textbox control (for simplicity call it Text1) with autopostback turned on. It has a couple validators: RequiredFieldValidator_Text1 RegularExpressionValidator_Text1 The Text1...
8
by: copyco | last post by:
I want to be able to test if my app's form has focus, (ie: not in background, behind other windows). How can I do this? I tried the Me.Focused, but that doesn't work. I think it's because a...
1
by: clickon | last post by:
For testing purposes i have got a 2 step WizardControl. Eqach step contains a text box, TextBox1 and TextBox2 respectively. If i put the following code in the respective activate event handlers...
0
by: mike | last post by:
Hi, When I programatically Bind a DataSource to DetailsView it does not fire "ModeChanged" event. This is first time i am trying to use ASP.NET DetailsView control. I have played with some of the...
9
by: Zytan | last post by:
http://msdn2.microsoft.com/en-us/system.windows.forms.control.focus(VS.80).aspx this page says: "Focus is a low-level method intended primarily for custom control authors. Instead, application...
4
by: Rafael A. M. Borges | last post by:
Hi, How can I set the focus on the first control in the page? I tried Page.Controls(0).Focus() but it didn't works. Does anyone knows it?
8
by: Mel | last post by:
I have several text boxes and drop-down lists in an AJAX Update Panel. All user inputs have the Postback property set to True. After I type something in the first input entry and press the "Tab"...
10
by: Derek Hart | last post by:
I can set focus to my property grid by using propgrid.Focus - but how can I set the default property that is always first? Or just set focus to the default property? Can this be done?
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.