Maybe u should try different coordinates, or you can try to get the handle of the focussed childwindow. But if you know the handle or classname of the editfield already you can setfocus to them. (and then you can use the WM_SetText message)
Do you mean all aplications or all processes?
For all applications I did it like this:
function EnumWindowsProc(Handle: HWND;param: LPARAM): LongBool; stdcall;
var Buffer: array[0..1024] of Char;
begin
Result:=True;
if GetWindowLong(Handle,GWL_STYLE) AND WS_VISIBLE=0 then Exit...
I did it like this:
procedure SetREBackColor(RE: TRichEdit; Color: TColor);
var
CharFormat2: TCharFormat2;
begin
FillChar(CharFormat2, SizeOf(CharFormat2), 0);
CharFormat2.cbSize := SizeOf(TCharFormat2);
CharFormat2.dwMask := CFM_BACKCOLOR;
CharFormat2.crBackColor := Color...
I want to change the font Fore- AND Back-groundcolor of an editable field. I tried it with an standard edit field and a richeditfield, but i can only find how to change the Foreground color. Does anybody have an idea how to do this?
Since I can't find a way to read and write the external editfield directly, I decided to use the clipboard as an interface between the external and mine program.
I copy selected text to the clipboard into my program by simulating the CTRL-C keypress. Maybe there another (better) way for doing...
It works when you use:
if GetKeyState(VK_NumLock) <> 0 then //numlock not off??
begin
//press numlock
keybd_event(VK_NumLock, $45, KEYEVENTF_EXTENDEDKEY, 0);
//release numlock
keybd_event(VK_NumLock, $45, KEYEVENTF_EXTENDEDKEY or KEYEVENTF_KEYUP, 0);
end;
I have tried that already, but I have the same problem. I also found a component "keyled" which (re)sets num-, caps- & scroll-lock, but then my application resets numlock only when my application is the active window. Also when the mousecursor is on top of my application it switches...
Button1 on Form1 - disable mouse and keyboard for 5 seconds:
~~~~~~~~~~~~~~~~~~~~~~~~~
procedure TForm1.Button1Click(Sender: TObject) ;
function FuncAvail
(_dllname, _funcname: string; var _p: pointer):
boolean;
var _lib: tHandle;
begin
Result := false;
_p := NIL;
if...
I want to disable the Numlock key with a delphi application. I have tried the keyboardstate statements, but I can't get it to work. Does anyone know a way to do this or how to use the keyboardstate things?
Instead of everything going italic, i ment:
I already thought so, but is there anyway to do this automaticly instead of creating them all? (like dlg[i] or something)
I already thought so, but is there anyway to do this automaticly instead of creating them all? (like dlg[i] or something)
I already did this.
I ment...When I only use one dialog that popped up more then once, how does the mainform know wich one sended a result, but that doesn't matter since...
Now the tricky part of the problem:
I have more than one button that shows a dialog. Can I use the form "dlg" more than once at the same time?
When I twice press a button that shows a dialog, I'll get a dialog twice, but for some reason the procedures YesClick and NoClick don't run...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.