skymouse
asked on
change other program's caption
I wasnt to change other program's caption to other name. for example, if program's caption is ICQ, i want to change to other name, how can i do it? use DDE? or use other method? can u teach me?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I tried it, it worked, thanx~
Can u help me again?
if i dont want to change icq caption only, want to change any active window, how can i find out the active window then change the caption?
thanxxxxxxxxxxxx
Can u help me again?
if i dont want to change icq caption only, want to change any active window, how can i find out the active window then change the caption?
thanxxxxxxxxxxxx
How about accepting the answer and then add a new question :-)
procedure TForm1.Button1Click(Sender : TObject);
var
h:hwnd;
s : string;
begin
s := 'hello';
h :=getforegroundwindow;
sendmessage(h,wm_settext,0 ,longint(s ));
end;
var
h:hwnd;
s : string;
begin
s := 'hello';
h :=getforegroundwindow;
sendmessage(h,wm_settext,0
end;
ASKER
hmm.............i should close the old question and open a new one, sorry PeterLarsen, what can i do?
-Use FindWindow to catch the window handle of the other app
....HWnd:=FindWindow( "OldCaption", nil );
- Use SendMessage( HWnd, WM_SETTEXT, 0, integer( @NeCaption ) ).
T++, Radler.