Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / October 2005

Tip: Looking for answers? Try searching our database.

Move  Picturebox  within its parent

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
sam - 28 Oct 2005 17:01 GMT
Hello,
      I am looking for a way to move around (drag/drop) a picturebox
placed in a panel like the capability provided during the design time.
The movement is only confined to its parent- the panel. Just not able
to find a resource out there. Any pointer would be great!!

Thanks,
Sam.
Sanjeevakumar Hiremath - 31 Oct 2005 09:12 GMT
This gives a general idea of going about your problem. You need to optimize
and use some mathematical(micro) adjustments for making it work flawlessly..
I have done the similar implementation in one of my previous assignments.
This should give you a good poit to start.

Hope this is helpful.

 private void pictureBox1_MouseMove(object sender,
System.Windows.Forms.MouseEventArgs e)
 {
      if ( e.Button == MouseButtons.Left )
      {
           this.pictureBox1.Location = new Point(e.X,e.Y);
      }
 }

Signature

Regards,
Sanjeevakumar Hiremath
Proteans Software Solutions
http://sharpnet.blogspot.com

> Hello,
>       I am looking for a way to move around (drag/drop) a picturebox
[quoted text clipped - 4 lines]
> Thanks,
> Sam.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.