Here's one way to do it:
Make cursor files with Imageedit:
CircleCross.cur;
Cross1.cur;
HandGrab.cur;
MagnCur.cur;
Add these to the program's resource area with the old Borland
Resource Workshop (download from Borland), or perhaps put them there
directly with the image editor (I haven't tried this).
In a unit with global variables accessible everywhere included in all
other units implementation clause:
const
crCircleCross = 1200;
crCross1 = 1300;
crHandGrab = 1400;
crMagnCur = 1500;
The constants must be greater than 1000 so as not to conflict with
standard cursors.
In the Main Program's
.FormCreate:
With Screen do
begin
Cursors[crCircleCross] := LoadCursor(Hinstance, 'CROSSCURSOR');
Cursors[crCross1] := LoadCursor(Hinstance, 'CROSS1');
Cursors[crHandGrab] := LoadCursor(Hinstance, 'HANDGRAB');
Cursors[crMagnCur] := LoadCursor(Hinstance, 'MAGNCUR');
end;
with the cursor files in the same directory as the executable.
Capital letters for the cursor names are required.
Select the cursor as needed with Screen.Cursor := crCircleCross; for example.
Irwin Scollar
_______________________________________________
Delphi mailing list -> [email protected]
http://www.elists.org/mailman/listinfo/delphi