Moving the cursor in a CEdit Control

What's the proper way to programmatically move a CEdit control's
cursor?  I've attempted to call SetFocus and then SetCaretPos, but
this doesn't seem to work.  Any Ideas?

Thanks,
Jeff
0
7/30/2004 3:22:20 PM
vc.mfc 33608 articles. 0 followers. Follow

1 Replies
344 Views

Similar Articles

[PageSpeed] 44

    CEdit::SetSel()

-- 
Cheers
Check Abdoul [VC++ MVP]
-----------------------------------

"J. Mullins" <jmullins@ccs.neu.edu> wrote in message
news:3bd86067.0407300722.6574b0d0@posting.google.com...
> What's the proper way to programmatically move a CEdit control's
> cursor?  I've attempted to call SetFocus and then SetCaretPos, but
> this doesn't seem to work.  Any Ideas?
>
> Thanks,
> Jeff


0
CheckAbdoul
7/30/2004 6:48:34 PM
Reply:

Similar Artilces:

Member Server to Domain Controller
Hi How do I promote a member server running Windows 2003 Server SP2 and Certificate Services to a domain controller. Regards Use the system command dcpromo Check out the link below http://www.petri.co.il/how_to_install_active_directory_on_windows_2003.htm -- Paul Bergson MVP - Directory Services MCITP - Enterprise Administrator MCTS, MCT, MCSE, MCSA, MCP, Security +, BS CSci 2008, Vista, 2003, 2000 (Early Achiever), NT4 Microsoft's Thrive IT Pro of the Month - June 2009 http://www.pbbergs.com Please no e-mails, any questions should be posted in the NewGroups. ...

Tab key moves
Can I pre-select which cell the tab key moves me to? I have a specific order I would like to follow each time. Is there a way I can fill out one area of my form before having to tab through another area? Not in a reasonable userfriendly way, no. The default behavior is left-to-right next unlocked cell, top to bottom. (But that is IMO how your application should be designed anyway.) HTH. Best wishes Harald "DCZ" <DCZ@discussions.microsoft.com> skrev i melding news:43C38961-D5BF-4F45-9CF5-DF2CD5958E9D@microsoft.com... > Can I pre-select which cell the tab key moves me to?...

SetWindowPos ZOrder does not work with overlapping controls?
Hello NG, I have a problem with the ZOrder of SetWindowPos. In my CDialog, I use a bitmap CStatic to display a background picture. On that, I want to show some controls. I do it as follows: m_stcBackgroundPic.SetWindowPos(&wndBottom, 0,0,1024,496, SWP_HIDEWINDOW); m_btnDoSomething.SetWindowPos(&wndTop, 10,10,100,60, SWP_HIDEWINDOW); m_stcEditCaption.SetWindowPos(&wndTop, 10,175,150,30, SWP_HIDEWINDOW); m_ctlEdit.SetWindowPos(&wndTop, 170,175,170,30, SWP_HIDEWINDOW); Later, I show the controls with ShowWindow in the same order as above (first the background pic, then the butt...

Cant move my database :-(
When I move my ms access database to a new machine i get a message saying that the event proceedure on mousedown etc bla bla bla and the date fields do not populate. When I return to the pc i built the damn thing on it works like a dream! Anyone got any ideas? Cheers If you want help, you'd be best off saying exactly what "bla bla bla" is. It's like going to a mechanic and saying "my car did something: fix it". Is your application split into a front-end (containing the queries, forms, reports, macros and modules), linked to a back-end (containing the tables...

Moving user profile to D:
Just re-installed Vista + moved 3 users from C:/Users to D:/ +moved all their old (pre-install) files from old user profile to new user profile on D: Still having few issues with permissions/installing There must be a proper (belt & braces) way to move user profile but how? "Chris K" <reply@the.board> wrote in message news:Ibg7o.56701$LU.1438@hurricane... > Just re-installed Vista + moved 3 users from C:/Users to D:/ +moved all > their old (pre-install) files from old user profile to new user profile on > D: > > Still having few issue...

Can't move worksheet to new workbook
I have a client who has always imported comma delimited files into Excel and then copied that worksheet into a master .xls workbook using the Move function. With Excel 2007 this is no longer working. It gives an error stating that the destination does not have enough rows and columns. However this move function works if moving a worksheet that started off as an .xls file - not .txt. Could someone please offer some assistance? Thank you. Hi David Could you provide a few more details. You talk about comma delimited files at the beginning, then .txt files at the end. Are these files...

Please help, Issues moving a CRM4 database to a new server and dom
Hi, I know there are a few posts here about this but nothing works for me. My Goal is to move a database to another server in another location with a different domain. Here is what I tried. I backed up the database on the current server (domain name: serverusa). I did backup both the MSCRM and the Config. First I tried to install MSCRM fresh on the new server (Domain name: server-ebm) I then checked it and I could access the CRM fine on the server using IE. Then I did go to the SQM management and restored the MSCRM database from a dump. After this I can access but it tells me "Inva...

Moving files from inbox to personal folder
WHEN TRYING TO MOVE FILES FROM INBOX TO PERSONAL FOLDERS USER GETS AN ERROR AND THE ACTION DOES NOT COMPLETE. ALL SETTING APPEAR TO BE CORRECT AND THERE IS ALSO NO VISIBLE SECURITY ISSUE. Error Messages: ITEM COULD NOT BE MOVED. IT HAS EITHER ALREADY BEEN MOVED OR ACCESS HAS BEEN DENIED. Don't use CAPS!!! Clear the Deleted Items folder and try again. Otherwise post more info like version of Outlook. -- Robert Sparnaaij [MVP-Outlook] www.howto-outlook.com Tips of the month: -Backup and Restore -Create an Office XP CD slipstreamed with Service Pack 3 ----- "Troy" <...

Is there a way to go through all the controls on a MFC dialog?
hi, I need to get through all the controls in a MFC dialog without knowing their ID at design time. That mean that the program must get the id and then get the control. Is there a better solution? One thing is for sure, I have to get the CWnd* of all of the controls on a dialog. How do I do this? thanks ThunderMusic > I need to get through all the controls in a MFC dialog without knowing > their ID at design time. CWnd* pChild = MyDialog.GetWindow(GW_CHILD); while (pChild) { // your code... pChild = pChild->GetWindow(GW_HWNDNEXT); } thanks, it works... I had the GetWin...

Release VS2005 & XP Common Controls Manifest
Hi, I have a couple questions. 1) When upgrading an MFC project from VS2003 to VS2005, the manifest options in the upgraded project settings cause Windows not to recognise the embedded manifest (as a resource) and no hence no XP controls. 2) I thought that to fix this I would create a VS2005 MFC application and look at how it sets up the manifest. Setting up a single dialog based MFC App, (with "Common Control Manifest" ticked under Advanced) I assume should create an MFC app that includes the necessary manifest and project settings - however the resulting app does not inc...

Move from exchange 2003 to 2007
Recently I migrated to exchange 2007 from 2003. I still have the 03 box running, but have move 2 mailboxes to new server. I can recieve mail through the old server to new mailboxes but cant send any mail out the new boxes. any ideas why? On Mon, 19 Mar 2007 04:40:08 -0700, cowen <cowen@discussions.microsoft.com> wrote: >Recently I migrated to exchange 2007 from 2003. I still have the 03 box >running, but have move 2 mailboxes to new server. I can recieve mail through >the old server to new mailboxes but cant send any mail out the new boxes. any >ideas why? Is ther...

ActiveX control is not shown correctly in Access Reports print pre
Hi All, we are developing ActiveX control's to use in MS Access. The control works fine with Access form in design mode and running mode. But in case of reports the design mode shows the control correctly but when comes to print preview mode, the size and drawing on the control is not working properly. The same control works fine with Access 2002. The problem is found to be with Access 2000. We need to enable XP theme from UxTheme.dll(Microsoft provide) if theme is avaible in the system. The drawing of theme is alo goes wrong in Access 2000 reports print preview mode. please help ...

Moving to new computer
I'm running Money 2008 and recently added a new computer to my home network. I want to run Money on the new computer instead of the older one. My plan is to move the Money database to the new computer, install Money on the new computer using the same installation disk I used before on the older computer and then use the new install to open the moved database on the new computer. I do NOT want to continue running Money on the older computer and will uninstall it when I'm sure everything is OK on the new computer. Should that work OK? Will I still be legally licensed and get Mo...

weird CEdit behaviour
Hi, I would like to derive a CEdit control to add the following method: void SetFont(const CString& strFont,int nPointSize, int nWeight); My problem is if I add this prototype, in the implementation file the compiler only sees this method and cannot see the parent method SetFont(CFont* pfont, BOOL bRedraw=1), the one from Cwnd). If I remove the prototype I can call SetFont(CFont* pfont, BOOL bRedraw=1). How can I do this because if I want to add my method I need to be able to call the base class SetFont and my custom SetFont. Vince wrote: > Hi, > > I would like to derive a...

How to Drag/Move the IE control based Application
Hi All: I am developing Dialog based application. I have placed Microsoft WebBrowser control(IE control) on main Dialog of application. On the IE control, all messages are being passed to IE control. Now problem is that I am unable to drag/move this IE Control/Dialog. Any idea about moving IE control/Dialog Please help me in this regard. Regards, Ghazanfar Ali ...

ActiveX Control error message
When I try to open any of the RMS modules (Store Operations Mgr, for example) iwhich are nstalled on my server I get the following message: "ActiveX component can't create object" I AM able to open them on both of the other computers networked to that server. I am not very tech-savvy so I'm reluctant to try anything too technical to fix this, but do any of you have something simple that would work? Or at least something that would help diagnose the problem? Thanks. -- WineGuy Hi there, It depends on what version of RMS You have installed... Anyway, there is a so...

Access2007 ON_CLICK problem on IMAGE on a TAB CONTROL
Hi All, With Access 2003 i made a form with a tab control. One one of the pages there is an image control with an ON_CLICK event assigned to it (normal vba procedure). With Access2003 the ON_CLICK is executed correctly Exactly the same DB run under Access 2007 the ON_CLICK event is ignored...no reaction at all....... This problem does not seem to occur if the image is not on a tab control Nor does it appear when i replace the image with a Button control. Can anyone tell what is hapening ? Rob, this is a known issue, but it was fixed in the service pack Microsoft released this week. You c...

Make Bit field control value of float field
Hi. I've made bit field with the default options of yes and no: new_Q1 Then i've made a field to collect a amount of points, incase the bit is set to yes: new_Q1p. If i select the format of the bit value to "list" my script works fine. If I select "check box", it does not work. Can any one help me modyfi the script to work with the check box? Thanks Regards, Jacob Mondrup This is the script I use: ______________________________________________________________________________ var point = 0; var get_status = parseInt(crmForm.all.new_q1.DataValue); switch (get...

Cursor font?
Is there a font available that has all (or most) of the special characters used by Excel (and, perhaps, other Office apps)? I was just writing up a few notes for myself on how to make use of Text Boxes and it would be handy to include the Text Box cursor symbol (vertical line with small cross hair near the bottom). "Square Peg" <SquarePeg@Round.Hole> wrote in message news:40add4lh10t2f1p65cnhiu4ec1m9l525an@4ax.com... > Is there a font available that has all (or most) of the special > characters used by Excel (and, perhaps, other Office apps)? > > I was just writ...

How to control contact sharing between Sharepoint and Outlook
Hey all, assume we have a contact list in sharepoint (SP) with 50,000 items (customers). We also have a sales force of 100 people in several groups. Now the problem: If I share the SP contact list with the sales people via Outlook, everyone of them will receive the 50,000 names. How can I control the sharing of contacts between SP and Outlook so that every sales person only receives the customers for example related to the particular sales group or limited by other parameters. Thanks in advance, Harry Hi, STC-Harry, Though this is a "misc" issue because it spans m...

Move to Previous Location
Hi, Curser was in page1 of a document. I scrolled to page 5 and selected an item in page 5. Now I want to go to previous location. Is there a shortcut for doing this? Thanks! GoBack (Shift+F5). GoBack will skip back to the previous 5 edit points. -- Terry Farrell - MSWord MVP "Maanu" <Maanu@discussions.microsoft.com> wrote in message news:4B07034B-78EC-4B09-B015-6B7DFCF625E9@microsoft.com... > Hi, > > Curser was in page1 of a document. I scrolled to page 5 and selected an > item > in page 5. Now I want to go to previous location. >...

Moving Outlook Data file...
....from Windows XP Pro to Vista Home Premium 64. I've got just about everything the way I want it. I can see my folders on the left. I get the preview panes that I want. I've transferred my signatures. So far, there are two things I cannot do. First of all, when I check my mail, it asks me for my password even though I have saved it when I created the e-mail account. Second, when I compose an e-mail, I can't access my Contacts even though they are right there on the left in my folder list (and I can see every entry when I click on Contacts). What do I need to do? Thank yo...

CImage, CStatic (Picture Control), CObArray problem
Please help! I need to create a dialog where the user can add, remove and navigate among images - one image shown at a time. So, I created the dialog, added the buttons for adding and so on, and a CStatic picture control to display one image. The dialog has got tabs, where the image handling is on one of the tabs. The pictures are stored in a CObArray as CImages. However, absolutely nothing works with these images... I've tried just about every tip I've found in this group, at MSDN, GodeGuru and everywhere. It might be because I'm not that experienced and clever VC-programmer. So ...

Moving Data Points on Scatter Chart in 2007
I have used Excel to construct various ship curves in all versions until 2007. I would create a table of offsets (x,y points) and build a simple integration scheme around the table. I would then graph the offsets. I could go into the graph, grab a particular data point and move it either horizontally or vertically. This would update the table and update the integration. I would have the area (or volume) display on the graph. So I could fair a smooth curve by adjusting offsets (with the smooth lines turned on) until I got the area and centroid I needed. Until Excel 2007! I cannot...

rule to move messages from senders who are on a personal dist list
Hi, I'd like to create a rule that will move messages that I receive from senders who are on one of my personal address book distribution lists. I would like to move the messages to a folder. However, when I try to create a rule I get this message: 'Cleanup Address List' is a personal distribution list that may not be used with this feature. Would you like to use the individual members of 'Cleanup Address List' instead? I am choosing "New Rule" then "Move messages from someone to a folder." Is there some other way to accomplish this ...