How to create Dragable and Resizable control

Please support our C# advertiser: Intel Parallel Studio Home
Reply

Join Date: Feb 2005
Posts: 9
Reputation: saurabh singh is an unknown quantity at this point 
Solved Threads: 0
saurabh singh saurabh singh is offline Offline
Newbie Poster

How to create Dragable and Resizable control

 
0
  #1
Mar 14th, 2008
I have to create a usercontrol which could be dragged over the base form and could be resizable during run time.
Please help me out.
Reply With Quote Quick reply to this message  
Join Date: Aug 2006
Posts: 2,065
Reputation: Ramy Mahrous is just really nice Ramy Mahrous is just really nice Ramy Mahrous is just really nice Ramy Mahrous is just really nice 
Solved Threads: 256
Featured Poster
Ramy Mahrous's Avatar
Ramy Mahrous Ramy Mahrous is offline Offline
Postaholic

Re: How to create Dragable and Resizable control

 
0
  #2
Mar 14th, 2008
To make a user control dragable or moveble on your forum you should make it using 3 event handlers
1- on mouse click
2- on mouse move
3- on mouse release

first on mouse click begin assgining the location of the control to the x, y of mouse
once user release mouse on the control don't make the mouse x, y = to user control.
I've sample on my pc I've implemented I'll search for you..

Resizable would be the same thinking..
BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
Reply With Quote Quick reply to this message  
Join Date: Feb 2005
Posts: 9
Reputation: saurabh singh is an unknown quantity at this point 
Solved Threads: 0
saurabh singh saurabh singh is offline Offline
Newbie Poster

Re: How to create Dragable and Resizable control

 
0
  #3
Mar 14th, 2008
I have already done this but problem is mouse move event for usercontrol can't displace it with respect to parent form.
Last edited by saurabh singh; Mar 14th, 2008 at 12:01 pm.
Reply With Quote Quick reply to this message  
Join Date: Apr 2008
Posts: 1
Reputation: beni_dude is an unknown quantity at this point 
Solved Threads: 0
beni_dude beni_dude is offline Offline
Newbie Poster

Re: How to create Dragable and Resizable control

 
0
  #4
Apr 15th, 2008
And do I assign the control the mouse positions?
Reply With Quote Quick reply to this message  
Join Date: Jul 2007
Posts: 300
Reputation: jireh is an unknown quantity at this point 
Solved Threads: 42
jireh's Avatar
jireh jireh is offline Offline
Posting Whiz

Re: How to create Dragable and Resizable control

 
0
  #5
Oct 30th, 2008
use also the drag and drop method
Reply With Quote Quick reply to this message  
Join Date: Oct 2007
Posts: 172
Reputation: Jugortha is an unknown quantity at this point 
Solved Threads: 16
Jugortha Jugortha is offline Offline
Junior Poster

Re: How to create Dragable and Resizable control

 
0
  #6
Oct 30th, 2008
Originally Posted by RamyMahrous View Post
To make a user control dragable or moveble on your forum you should make it using 3 event handlers
1- on mouse click
2- on mouse move
3- on mouse release

first on mouse click begin assgining the location of the control to the x, y of mouse
once user release mouse on the control don't make the mouse x, y = to user control.
I've sample on my pc I've implemented I'll search for you..

Resizable would be the same thinking..
Oh Ramy, it's a long time, how are you?
Reply With Quote Quick reply to this message  
Join Date: Oct 2007
Posts: 172
Reputation: Jugortha is an unknown quantity at this point 
Solved Threads: 16
Jugortha Jugortha is offline Offline
Junior Poster

Re: How to create Dragable and Resizable control

 
0
  #7
Oct 30th, 2008
This is a document within it there is an use cases about the drag and drop controls and how to deal with this
Attached Files
File Type: doc SampleApps_CSharp_DragDrop.doc (38.5 KB, 51 views)
Reply With Quote Quick reply to this message  
Join Date: Aug 2006
Posts: 2,065
Reputation: Ramy Mahrous is just really nice Ramy Mahrous is just really nice Ramy Mahrous is just really nice Ramy Mahrous is just really nice 
Solved Threads: 256
Featured Poster
Ramy Mahrous's Avatar
Ramy Mahrous Ramy Mahrous is offline Offline
Postaholic

Re: How to create Dragable and Resizable control

 
0
  #8
Oct 31st, 2008
I went back, I was busy last days with my conscription.. thanks for asking
BI Developer | LINKdotNET
B.Sc Computer Science, Helwan University
Technical blog | http://ramymahrous.wordpress.com
LinkedIn | http://www.linkedin.com/in/ramymahrous
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the C# Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC