Click here to Skip to main content
15,897,371 members
Home / Discussions / C#
   

C#

 
GeneralRe: Replace one character for another in a string Pin
kani9820-Feb-07 14:17
kani9820-Feb-07 14:17 
GeneralRe: Replace one character for another in a string Pin
Christian Graus20-Feb-07 14:38
protectorChristian Graus20-Feb-07 14:38 
QuestionDesigner Customization challenge... Pin
@FrankDrebin@20-Feb-07 13:25
@FrankDrebin@20-Feb-07 13:25 
QuestionIntercepting Output from another application Pin
shatterstar645720-Feb-07 13:18
shatterstar645720-Feb-07 13:18 
AnswerRe: Intercepting Output from another application Pin
mike montagne20-Feb-07 13:21
mike montagne20-Feb-07 13:21 
AnswerRe: Intercepting Output from another application Pin
Dave Kreskowiak20-Feb-07 13:36
mveDave Kreskowiak20-Feb-07 13:36 
GeneralRe: Intercepting Output from another application Pin
shatterstar645720-Feb-07 18:19
shatterstar645720-Feb-07 18:19 
GeneralRe: Intercepting Output from another application Pin
Dave Kreskowiak21-Feb-07 4:25
mveDave Kreskowiak21-Feb-07 4:25 
There's no easy way to do this. You can't "intercept" the text as it goes to the window. It's not like a console app that has a stream that you can redirect. There's nothing to redirect in this case.

Your best shot is going to be something like sending the WM_GETTEXT message to the window handle that is show you the text. HOPEFULLY, it responds and actually sends you the text that it is displaying. There's a couple of problems with this though.

First, there is nothing that says a window that displays text has to respond to the WM_GETTEXT message. It's a crap shoot if it does or not. You just have to try it. Google for "VB.NET WM_GETTEXT" for some examples.

Second, If WM_GETTEXT works, it'll give you everything that is in its text buffer, regardless if it sent you that text before or not. You'll have to work out what data you already have versus what you don't. On top of that, you won't get any indication or event to catch when the text changes in that window. You'll have to poll for it, constantly.



Dave Kreskowiak
Microsoft MVP - Visual Basic


Questiondetect a color using C++ Pin
ricardo montemayor20-Feb-07 13:03
ricardo montemayor20-Feb-07 13:03 
AnswerRe: detect a color using C++ Pin
Dave Kreskowiak20-Feb-07 13:14
mveDave Kreskowiak20-Feb-07 13:14 
GeneralRe: detect a color using C++ Pin
ricardo montemayor20-Feb-07 14:14
ricardo montemayor20-Feb-07 14:14 
GeneralRe: detect a color using C++ Pin
Christian Graus20-Feb-07 17:18
protectorChristian Graus20-Feb-07 17:18 
QuestionConverting Array int[] to List Pin
srivatsan2420-Feb-07 12:48
srivatsan2420-Feb-07 12:48 
AnswerRe: Converting Array int[] to List Pin
tgrt20-Feb-07 12:52
tgrt20-Feb-07 12:52 
AnswerRe: Converting Array int[] to List Pin
Judah Gabriel Himango20-Feb-07 12:57
sponsorJudah Gabriel Himango20-Feb-07 12:57 
GeneralRe: Converting Array int[] to List Pin
srivatsan2420-Feb-07 14:01
srivatsan2420-Feb-07 14:01 
AnswerRe: Converting Array int[] to List Pin
srivatsan2421-Feb-07 3:56
srivatsan2421-Feb-07 3:56 
QuestionSending data from Child to parent Form Pin
Khoramdin20-Feb-07 11:58
Khoramdin20-Feb-07 11:58 
AnswerRe: Sending data from Child to parent Form Pin
mike montagne20-Feb-07 12:30
mike montagne20-Feb-07 12:30 
AnswerRe: Sending data from Child to parent Form Pin
Martin#20-Feb-07 21:28
Martin#20-Feb-07 21:28 
QuestionC# in 2005 Pin
jotorres20-Feb-07 11:11
jotorres20-Feb-07 11:11 
AnswerRe: C# in 2005 Pin
Guffa20-Feb-07 11:53
Guffa20-Feb-07 11:53 
GeneralRe: C# in 2005 Pin
jotorres20-Feb-07 12:16
jotorres20-Feb-07 12:16 
AnswerRe: C# in 2005 Pin
Guffa24-Feb-07 4:08
Guffa24-Feb-07 4:08 
AnswerRe: C# in 2005 Pin
tgrt20-Feb-07 12:27
tgrt20-Feb-07 12:27 

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.