Solved

connect two images on the form by line in run time

Posted on 2004-04-28
5
169 Views
Last Modified: 2010-04-24
i am implementing RF simulator and i am in the GUI phase i want to know how i can connect two images (which represent two elements) by line in run time such that user can make wire connections in the circuit
thanks
0
Comment
Question by:mahmoudatiya
  • 2
5 Comments
 
LVL 2

Expert Comment

by:Jeffr0
ID: 10938202
GDI+ is the .Net toolkit for this.

You'll need a Pen object to draw it.  (System.Drawing.Pen)
0
 
LVL 2

Accepted Solution

by:
Jeffr0 earned 50 total points
ID: 10938225
Put this code in the Paint event of your form for an example:

        Dim bit As Bitmap = New Bitmap(Me.Width, Me.Height)
        Dim g As Graphics = Graphics.FromImage(bit)
        Dim myPen As Pen = New Pen (Color.Blue, 3)

        Me.CreateGraphics.DrawLine(myPen, 0, 0, Me.Width, Me.Height)
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Article by: Kraeven
Introduction Remote Share is a simple remote sharing tool, enabling you to see, add and remove remote or local shares. The application is written in VB.NET targeting the .NET framework 2.0. The source code and the compiled programs have been in…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now