Archive for August, 2007

26 Aug

Taskbar position

For some applications, it’s important to know, where the taskbar is located. Of course, most users use standard “bottom of the screen” position, but of course, you can place it to the left, rigtht or top of the screen. Here is the method to determine actual position.

22 Aug

Just one instance of application

If want to allow users to run just one instance of application, one of possible methods is to use “mutext” (mutual exclusion).

18 Aug

Retrieve time since the system was started

This tip is very simple. Just use standard function GetTickCount and the rest is just elementary mathematics.

18 Aug

Determine CPU frequency

Here is just small piece of assembler code to determine CPU frequency in MHz.

18 Aug

Hide /show taskbar clock

Simple function to show and hide taskbar clock.

18 Aug

Simulate mouse moves and clicks

You can move mouse cursor and simulate clicking programmatically using just one simple procedure.

18 Aug

Hide / show all icons on desktop

Another “one-line code trick” and probably completely useless.

18 Aug

Animate application icon (on taskbar and apllication window)

This trick is pretty simple. You just need few icons (at least two) for animation and Timer component. The rest is easy…