Ok,
This Function waits for the given time for a key, and returns the char wich is pressed or #0 if an timeout ocours.
It is not verry exact, becourse the Systemcall "keypressed" takes a little time. Bigger value of the "TimeStep"-const will give a more acurad time, but less responsetime for...
Thanks,
your code helped me to find my mistake. It was is simple misnamed Variable (damt copy & paste ;-) )... As Parameter I used NewIcon... and in the codeblock I wrote
hicon := Icon.handle
I changed it to
hicon := NewIcon.handle
and everything works fine.
again thanks for the answer...
I want to make an Application, that send to the windows-IconTaskBar when it the window is minimized.
with the function
procedure TForm1.IconTaskBar_show(Icon:TIcon; Hint:string);
var vIconTaskBar : TNotifyIconData;
begin
Hint := copy(Hint, 1, 63); // maximum size of the hint-field...
Hi,
a simple loop should do this...
oldX5 := X5;
repeat
x5:=random(4)+1;
until X5 <> oldX5;
the repeat-loop will never leave until X5 is another Value than the OldX5...
You shold set X5 at the begin of your game so something lik -1... it is not function-relevant, but it looks better if...
well I the function ShowModal never returns until the
Dialog that it shows had closes.
If you use showmodal the Form should Close it with
ModalResult := mrOK;
instead
Form2.close
"ModalResult := mrOK;" close the Modal Dialog and Return the Integer (here mrOK, but any othr...
I think that buffer is an array of 32-Bit integers, and you are working an a 80x86 mashine. The best way is to acess the array by its bytes, so you don't have to do any shifting.
mov ecx, 128*640-1
lea esi, buffer
@@LoopStart:
; read the colors
mov al, Byte Ptr [esi+ecx*4][0]; read red
;mov...
Windows handles Dialogs(and controlls) like windows.
So a Window get the WM_PAINT-Message afer the WM_SIZE-Message when it will be initialisied.
The WM_INITDIALOG comes before the WM_SIZE-Message, so the size of the window(or controll) is still zero.
Messagesorder send to the window...
I want to write a password-Dialog. Before the user enters a password he should be warned if a keyboard-hook is looking on his fingers.
Is it posible to get a List of the hooks that are curently registered as keyboard-hooks. (or other hooks)
First you can use the horner-rule. Then you need no loops, you save a few multplikations, and gets a more accurat result.
y= 3x^4 - 17x^3 + 14x^2 - 23x + 23
y= (((3*x- 17)*x + 14)*x - 23)*x + 23; ==> only 4 multiplies
anyway the endless-loops in your code is the wrong set af the label power4...
I use a memory-mapped-file to exchange some parameters with a global hook. Thats works fine, since I added a few more feelds. Now the mapping of the file fails.
I fixed the problem by giving the memory-mapped-file a new name. So I think Windows stores the filename and filesize somewhere in the...
Tell us more about the Problem...
Do you run the Program from the Boot-Sektor or from DOS or Windows?
Are there different Systems installed?
Wich BIOS calls are used?
What do the Programm...?
Use the Programm any non 8086-Code ? MMX and ISS ?
What is going wrong? System-Crash, Hang Up, Program...
I want to send a Text to an editor i.e. Notepad.
I post them an WM_KEYDOWN message with the Keycode I got from the function VkKeyCode(char), but all chars are convertet to lowercase.
Can anyone tell me why?
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.