473,387 Members | 1,669 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Moving graphics using the mouse

Hi Everyone:
I'm trying to make a simple windows application that allows me to draw a
shape on the form using a Graphics object. Drawing the shape is pretty
simple. My problem is I don't know how to capture the region of the shape and
place that into a container that I can move while holding the mouse button
down.

I have seen this done in many other Windows applications.

Can anyone point me in the direction I need to go? Sample code would be
wonderful.

Thanks,
--
Mark
Nov 20 '07 #1
1 1612
Please use Control.MouseMove Event.

http://www.alvas.net - Audio tools for C# and VB.Net developers
"Mark" <Ma**@discussions.microsoft.comсообщил/сообщила в новостях
следующее: news:AB**********************************@microsof t.com...
Hi Everyone:
I'm trying to make a simple windows application that allows me to draw a
shape on the form using a Graphics object. Drawing the shape is pretty
simple. My problem is I don't know how to capture the region of the shape
and
place that into a container that I can move while holding the mouse button
down.

I have seen this done in many other Windows applications.

Can anyone point me in the direction I need to go? Sample code would be
wonderful.

Thanks,
--
Mark

Nov 22 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: willem | last post by:
Hi, I want move my form with mouse when I press button over a different position from normal bar of title. I set MouseUp, MouseDown and, MouseMove events and all works good. is it...
6
by: johannblake | last post by:
I am wondering whether it is easy to setup a coordinate system for drawing (using GDI+) that uses meters (or any custom scaling for that matter). Currently, I need to convert from pixels to meters...
0
by: SStory | last post by:
I have a pnlControl in which I am using as a workspace on which to drag several pictures and drop them. These are bitmaps that are no more than 150x150 at the largest. I keep up with them and...
0
by: Gino | last post by:
Hi, I wish to code a control that writes a text over a picturebox and that can be dragged with mouse. Here is what i've actually coded to obtain a similar effect, but as you can see i've...
2
by: Carl Gilbert | last post by:
Hi I have a math kinda problem where I'm trying to split some lines when two or more lines connect two shapes. The reason I am doing this is to make it clear that there are multiple lines...
0
by: MrNobody | last post by:
I have a custom Panel which will have smaller custom Panels added and drawn within it. I want to be able to re-order the arrangement of the inner Panels using drag n drop, and I want to do this...
9
by: Peter Webb | last post by:
I want to animate one object moving in front of another. I cannot re-render the background as the object moves, as it would be extremely time consuming. This is what I would like to do. I draw...
12
by: =?Utf-8?B?TWFyaw==?= | last post by:
I modified a C# application from Bob Powell that moves graphics primitives around on the screen into a Vb.NET 2005 application. I want to modify this application so along with moving regular...
0
by: raylopez99 | last post by:
Hi, I'm getting into GDI+ Forms 2.0 graphics for C#3 using Visual Studio 2008. One thing I notice: the graphics are really slow and flicker on a Pentium IV, with 2 GB RAM, even with...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.