🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #14641

Re: Threads and Timer problem

#14641
From: Malcolm Smith
Date: Tue, 05 Aug 2003 14:47
78 lines
3682 bytes
Which version of BCB are you using.  Ignore the warning.  As for the error
I'll have to check - it worked fine when I wrote it <g>

To save me digging it out can you post (privately to
malcolm@mjfreelancing.com) the lines where the error is reported.

-- 
Malcolm Smith
MJ Freelancing- http://www.mjfreelancing.com
Software Protection for C++Builder
Borland Technology Partner


"Paul E." <paulepst69@aol.com> wrote in message
news:3f2e85b6@newsgroups.borland.com...
> Thanks maclolm, well first of all I am really so *NEW* to Threads, and I
am
> not insisting on using Synchronize calls, I am open to any suggestions,
> advise from anyone.
>
> My main task is that I have a few functions that must get executed every 5
> seconds, so I need to do this in a separate thread other than the main
> project thread...so I really need help with how I can change the code I
> posted to reach my main task...
>
> So if you can please let me know how I can adjust the code I posted to
reach
> my task...
>
> BTW I downloaded your tutorial, and it is really good, but a bit high on
my
> level in threads to understand, also it gives me 2 error when I try to run
> the project...
>
> [C++ Warning] main.h(75): W8027 Functions containing while are not
expanded
> inline
> [C++ Error] main.cpp(126): E2369 Cannot use the result of a property
> assignment as an rvalue
>
> thanks for your support
>
>
> "Malcolm Smith" <mjfreelancing@optusnet.com.au> wrote in message
> news:3f2e41c5$1@newsgroups.borland.com...
> > I forgot to mention, your code is no better than if you dropped a TTimer
> on
> > the form and made it active from the button click.  Your methods are
still
> > processed within the context of the main VCL thread because of the
> > Synchronize call.
> >
> > -- 
> > Malcolm Smith
> > MJ Freelancing- http://www.mjfreelancing.com
> > Software Protection for C++Builder
> > Borland Technology Partner
> >
> >
> > "Malcolm Smith" <mjfreelancing@optusnet.com.au> wrote in message
> > news:3f2e415c$1@newsgroups.borland.com...
> > > I'm not sure why you are triggering a TTimer this way.  If you are
after
> a
> > > thread that processes a task after a given period of time check out my
> > > tutorials page.  I have just the class for you.  Look for
> > TWaitEventThread.
> > >
> > > -- 
> > > Malcolm Smith
> > > MJ Freelancing- http://www.mjfreelancing.com
> > > Software Protection for C++Builder
> > > Borland Technology Partner
> > >
> >
> >
>
>
Technical Details
Message-ID: <3f2fc240$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3f2daa27@newsgroups.borland.com> <3f2e415c$1@newsgroups.borland.com> <3f2e41c5$1@newsgroups.borland.com> <3f2e85b6@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,ece7f64e3f770b72
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-08-05 07:46:23 PST
Reply-To: "Malcolm Smith" <mjfreelancing@optusnet.com.au>
From: "Malcolm Smith" <mjfreelancing@optusnet.com.au>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3f2daa27@newsgroups.borland.com> <3f2e415c$1@newsgroups.borland.com> <3f2e41c5$1@newsgroups.borland.com> <3f2e85b6@newsgroups.borland.com>
Subject: Re: Threads and Timer problem
Date: Wed, 6 Aug 2003 00:47:16 +1000
Lines: 80
Organization: MJ Freelancing
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 211.28.166.113
Message-ID: <3f2fc240$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1060094528 211.28.166.113 (5 Aug 2003 07:42:08 -0700)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-04!sn-xit-01!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail