Article View: borland.public.cppbuilder.nativeapi
Article #7807How to avoid the resize cursor on a form
From: Omar Zelaya
Date: Tue, 21 Dec 2004 02:34
Date: Tue, 21 Dec 2004 02:34
33 lines
1887 bytes
1887 bytes
Hi,
i have a form with borderstyle resizable, but i want it to act as a
dialog(no reisize) i have set the event canResize but i want to avoid the
resize cursor also.
I have added the following code but now i'm not able to select the form by
clicking the caption bar or click on any button on the caption bar.
wha am i doing wrong or need to add to my code?
Thanks in advance
//in h file
BEGIN_MESSAGE_MAP
MESSAGE_HANDLER(WM_NCHITTEST,TMessage,WMNCHitTest)
END_MESSAGE_MAP(TForm)
//in cpp file
void __fastcall TMainForm::WMNCHitTest(TMessage Msg)
{
TForm::Dispatch(&Msg);
switch(Msg.Result)
{ case HTLEFT:
case HTRIGHT:
case HTBOTTOM:
case HTBOTTOMRIGHT:
case HTBOTTOMLEFT:
case HTTOP:
case HTTOPRIGHT:
case HTTOPLEFT:
Msg.Result = HTNOWHERE;
break;
}
Technical Details
Message-ID:
<41c78873$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,defb858d2b68ec70,start X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Omar Zelaya" <ozelaya@invdochat.com> Newsgroups: borland.public.cppbuilder.nativeapi Subject: How to avoid the resize cursor on a form Date: Mon, 20 Dec 2004 20:34:41 -0600 Lines: 35 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-RFC2646: Format=Flowed; Original NNTP-Posting-Host: 63.245.8.17 Message-ID: <41c78873$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1103595635 63.245.8.17 (20 Dec 2004 18:20:35 -0800) Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!feeder.enertel.nl!nntpfeed-01.ops.asmr-01.energis-idc.net!216.196.110.149.MISMATCH!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail