|
-
Jun 1st, 2006, 06:10 PM
#1
Thread Starter
Junior Member
How to draw on an image? [2005]
I'm trying to draw a dot onto an image.
I can do it is asp.NET but nothing is happening when I do the following as part of a Windows Application. An better example would be great.
Any suggestion please?
Imports System.Drawing
Imports System.Drawing.Imaging
Imports System.Drawing.Drawing2D
Public Class DrawImagewithDot
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim objBitmap As New Bitmap("C:\myIMG.bmp")
Dim g As Graphics = Graphics.FromImage(objBitmap)
Dim redBrush As New SolidBrush(Color.Red)
Dim blueBrush As New SolidBrush(Color.Blue)
g.FillEllipse(blueBrush, 100, 206, 10, 10)
g.FillEllipse(redBrush, 200, 180, 10, 10)
g.DrawImage(objBitmap, 10, 10)
End Sub
End Class
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|