Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Thursday, June 12, 2008 3:18:16 AM(UTC)
leftback

Groups: Registered
Posts: 28


Using c#,wpf and version 15

is there a way to do this in a wpf app hosting a forms control that hosts the rasterviewer??

Thanks
 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Thursday, June 12, 2008 10:31:04 AM(UTC)

GregR  
GregR

Groups: Registered, Tech Support, Administrators
Posts: 764


LEADTOOLS doesn't have anything to move the mouse cursor.  You will need to declare and use the API function SetCursorPos and ClientToScreen.

I've never tried it in WPF, but I would imagine you can get the client coordinates of the RasterImageViewer relative to the WPF form and then do the math and pass the correct point.  There might be a better way to do this as far as doing the math to get the point you want, but it's more of a Windows API/WPF API issue.  If you have any more questions regarding this you should contact Microsoft. 

Here's an example of how to declare those API functions and center the cursor on a button.

http://swigartconsulting.blogs.com/tech_blender/2005/08/how_to_move_the.html
 
#3 Posted : Thursday, June 12, 2008 10:56:05 PM(UTC)
leftback

Groups: Registered
Posts: 28


Thats brilliant thanks, yeah I was already thinkng of using API stuff for the mouse cursor but it was the client coordinates of the RasterImageViewer that I had overlooked.

Cheers!!
 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.060 seconds.