Article View: borland.public.cppbuilder.nativeapi
Article #612Re: SHBrowseForFolder Function and highlighting text in the dialog's EDIT box
From: Daryl
Date: Sat, 02 Feb 2008 02:08
Date: Sat, 02 Feb 2008 02:08
21 lines
1803 bytes
1803 bytes
>>> Is it possible after the error message is closed to highlight >>> the incorrect folder name in the EDIT box in the Browse >>> for Folder dialog? >> >> Not directly. You would have to manually find the HWND of the edit field >> and then pass it to SetFocus(). > > How could I go about manually find the HWND of the edit field? I tried this: HWND hwndEdit = FindWindowEx(hwnd, NULL, "Edit", NULL); // hwnd is the handle to the dialog. SendMessage(hwndEdit, WM_SETTEXT, 0, (long)""); This seems to work, does it look OK? I would like to know how to highlight the text in the EDIT box, instead of deleting it - can you assist? thanks daryl
Technical Details
Message-ID:
<47a3d09e@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news1.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mailReferences:
<47a3a07f@newsgroups.borland.com> <47a3b6ac$1@newsgroups.borland.com> <47a3c3a9@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,b9ce09f85e82d150 X-Google-Attributes: gid10cc67,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit From: "Daryl" <devaccount@hotmail.com> Newsgroups: borland.public.cppbuilder.nativeapi References: <47a3a07f@newsgroups.borland.com> <47a3b6ac$1@newsgroups.borland.com> <47a3c3a9@newsgroups.borland.com> In-Reply-To: <47a3c3a9@newsgroups.borland.com> Subject: Re: SHBrowseForFolder Function and highlighting text in the dialog's EDIT box Date: Sat, 2 Feb 2008 12:08:32 +1000 Lines: 22 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Windows Mail 6.0.6000.16480 X-MimeOLE: Produced By Microsoft MimeOLE V6.0.6000.16545 NNTP-Posting-Host: 202.63.43.146 Message-ID: <47a3d09e@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1201918110 202.63.43.146 (1 Feb 2008 18:08:30 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news1.google.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail