HOTSPOT controls

Tinkerbell

New Member
Licensed User
Longtime User
Mine Doesn't Work

A simple Hotspot control using an Image control and the Door library takes very little code as long as you are happy with square hotspots. You would have to set up the co-ordinates of the hotspots anyway so the actual code is pretty minimal.

Hi Agraham:
I am doing a workaround for another problem and your HotSpots solution was just what I needed. However, even though your program works great on the PC, when compiled to PPC your program errors out for me. When compiled with nonoptimized I get the error "Error loading program ... Door.dll". When I compile With optimized I get the error "An error occured on sub_app_start ... NullReferenceException". In both cases I have the door.dll and hotspots.jpg in the application directory. I haven't had any compatibility problems with my Ipaq ppc before. Do you have any suggestion what my problem is?
Thank you.
 

agraham

Expert
Licensed User
Longtime User
There is no "MouseClick" event in the Compact Framework so change it to "MouseDown" (carefully note the case) at line 24. This should now work both optimised and non-optimised. The "splodge" test always misses (on my Axim X30 anyway) - probably because the RGB value returned on the device don't match the cRED constant. This is a known "feature" of devices as they have a limited colour palette for their displays, you will have to work that one through yourself.


When compiled with nonoptimized I get the error "Error loading program ... Door.dll".
If this persists I have no idea why. It works fine on my device, both legacy compiled and IDE, with that single change
 
Top