Click here to Skip to main content
15,888,158 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
QuestionGetting a the real object from it's handle Pin
Shyam K Pananghat24-Jun-07 20:24
Shyam K Pananghat24-Jun-07 20:24 
AnswerRe: Getting a the real object from it's handle Pin
Dave Kreskowiak25-Jun-07 4:07
mveDave Kreskowiak25-Jun-07 4:07 
GeneralRe: Getting a the real object from it's handle Pin
Shyam K Pananghat25-Jun-07 23:18
Shyam K Pananghat25-Jun-07 23:18 
QuestionDefault Fonts and Chinese Pin
nde_plume23-Jun-07 15:48
nde_plume23-Jun-07 15:48 
QuestionExecuting function on GUI-thread Pin
invictus323-Jun-07 8:48
invictus323-Jun-07 8:48 
AnswerRe: Executing function on GUI-thread Pin
Luc Pattyn23-Jun-07 9:04
sitebuilderLuc Pattyn23-Jun-07 9:04 
GeneralRe: Executing function on GUI-thread Pin
invictus323-Jun-07 9:12
invictus323-Jun-07 9:12 
GeneralRe: Executing function on GUI-thread Pin
Luc Pattyn23-Jun-07 9:58
sitebuilderLuc Pattyn23-Jun-07 9:58 
Aha, I see two possible ways to solve that:

1.
the official way: if your library is independent of the GUI, then it should
not be interested in the GUI thread either. If it needs something done by the app
it should use delegates/events to get the app's attention so it can process
the event. If (part of) the app's reaction needs to run on the GUI thread, then
that's the app's responsibility, so it must organize the InvokeRequired/Invoke stuff.

2.
a hack: create a GUI Control in your app, and pass it on to your library
(maybe thru a Property, possibly a static one). Now your library can use
Invoke itself. You should describe this behavior in your library's documentation
though, since now, even when called from a background thread, the library can load
the GUI thread and harm the resposiveness of the app that uses the library.

Smile | :)


GeneralRe: Executing function on GUI-thread Pin
invictus323-Jun-07 10:23
invictus323-Jun-07 10:23 
GeneralRe: Executing function on GUI-thread Pin
Luc Pattyn23-Jun-07 10:28
sitebuilderLuc Pattyn23-Jun-07 10:28 
GeneralRe: Executing function on GUI-thread Pin
invictus323-Jun-07 10:50
invictus323-Jun-07 10:50 
GeneralRe: Executing function on GUI-thread Pin
Luc Pattyn23-Jun-07 12:40
sitebuilderLuc Pattyn23-Jun-07 12:40 
Question.NET 3.5 Beta 1 Pin
Brendan Vogt22-Jun-07 6:16
Brendan Vogt22-Jun-07 6:16 
AnswerRe: .NET 3.5 Beta 1 Pin
Scott Dorman22-Jun-07 7:25
professionalScott Dorman22-Jun-07 7:25 
Question.NET 3.0 Getting Started Pin
Brendan Vogt22-Jun-07 6:14
Brendan Vogt22-Jun-07 6:14 
AnswerRe: .NET 3.0 Getting Started Pin
Scott Dorman22-Jun-07 7:25
professionalScott Dorman22-Jun-07 7:25 
AnswerRe: .NET 3.0 Getting Started Pin
Kevin McFarlane23-Jun-07 0:21
Kevin McFarlane23-Jun-07 0:21 
GeneralRe: .NET 3.0 Getting Started Pin
Brendan Vogt23-Jun-07 2:08
Brendan Vogt23-Jun-07 2:08 
QuestionInterop.MSXML2.dll Pin
Sebastian T Xavier22-Jun-07 0:13
Sebastian T Xavier22-Jun-07 0:13 
AnswerRe: Interop.MSXML2.dll Pin
Vasudevan Deepak Kumar22-Jun-07 5:27
Vasudevan Deepak Kumar22-Jun-07 5:27 
QuestionScroll a panel manually Pin
Dillipb21-Jun-07 19:29
Dillipb21-Jun-07 19:29 
AnswerRe: Scroll a panel manually Pin
Manas Bhardwaj22-Jun-07 5:24
professionalManas Bhardwaj22-Jun-07 5:24 
AnswerRe: Scroll a panel manually Pin
Vasudevan Deepak Kumar22-Jun-07 5:30
Vasudevan Deepak Kumar22-Jun-07 5:30 
QuestionC#/VS2005 Event fired on Network Activity Pin
xcguy8721-Jun-07 7:16
xcguy8721-Jun-07 7:16 
AnswerRe: C#/VS2005 Event fired on Network Activity Pin
Dave Kreskowiak21-Jun-07 7:48
mveDave Kreskowiak21-Jun-07 7:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.