Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2010-06

Accessing WinControls from DLL

3 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

SteveG

I believe that 'writing' (without syncronization) to a TWinControl from a thread or dll function is BAD(tm), but just wondering if the same applies to 'reading' (properties / etc) ?

another way - can 'non-mainthread' access to WinControls be considered 'ReadOnly'

Thanks - SteveG

Reply by email

Mattias Gaertner
to SteveG
Show quoted text 6 lines
I believe that 'writing' (without syncronization) to a TWinControl from a thread or dll function is BAD(tm), but just wondering if the same applies to 'reading' (properties / etc) ? another way - can 'non-mainthread' access to WinControls be considered 'ReadOnly'

In general: no
Apply the normal multithreading rules. You have to make sure the main thread does not write at the same time.

Mattias

Reply by email