Article View: borland.public.cppbuilder.nativeapi
Article #2325Re: VC++ CSemaphore equivalent?
From: DreamChaser
Date: Tue, 13 Mar 2007 01:15
Date: Tue, 13 Mar 2007 01:15
27 lines
2171 bytes
2171 bytes
Robert G. Hoover wrote: > Hi Dennis, > ie, the standard windows thread. So, I spawn a thread in my > TShellForm::FormCreate() function... > > > // spawn thread for advanced grab/display routines > hThread = (HANDLE)BeginThread(THREAD_PRIORITY_NORMAL, > 0, VideoGrabbingThread, > this, 0, ThreadID); > > // set thread priority > SetThreadPriority(hThread, THREAD_PRIORITY_LOWEST); > > Hey D, Before CPP police show up, thought I would throw this in. FormCreate() is only there because Pascal (i.e Delphi) needs it, not C++. You should all of your construction stuff in the form constructor. I have seen numerous references in these groups and elsewhere that FromCreate() "could" be fired prior to the Constructor being called. Although as near as I can tell it has something to do with the Phase of the Moon and the amount of rainfall in Africa that effects when this happens. ;) This of course may or may not have anything to with your problem, but.... DC
Technical Details
Message-ID:
<45f5faf9@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.maxwell.syr.edu!newsfeed.yul.equant.net!news-lond.gip.net!news.gsl.net!gip.net!colt.net!feeder.news-service.com!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<45f57403@newsgroups.borland.com> <45f57fd5@newsgroups.borland.com> <45f583fb$1@newsgroups.borland.com> <45f58df7$1@newsgroups.borland.com> <45F590EC.8090303@anywhere.sorry>Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,411b13b57e2ea81a X-Google-Attributes: gid10cc67,public X-Google-Language: ENGLISH,ASCII-7-bit Date: Mon, 12 Mar 2007 20:15:13 -0500 From: DreamChaser <NO-Spam@No-Span.net> User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) MIME-Version: 1.0 Newsgroups: borland.public.cppbuilder.nativeapi Subject: Re: VC++ CSemaphore equivalent? References: <45f57403@newsgroups.borland.com> <45f57fd5@newsgroups.borland.com> <45f583fb$1@newsgroups.borland.com> <45f58df7$1@newsgroups.borland.com> <45F590EC.8090303@anywhere.sorry> In-Reply-To: <45F590EC.8090303@anywhere.sorry> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 65.6.192.60 Message-ID: <45f5faf9@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1173748473 65.6.192.60 (12 Mar 2007 18:14:33 -0800) Lines: 27 Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.maxwell.syr.edu!newsfeed.yul.equant.net!news-lond.gip.net!news.gsl.net!gip.net!colt.net!feeder.news-service.com!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail