Creating Image file

Tech-Archive recommends: Fix windows errors by optimizing your registry




Hi All..

I am working in developing an application that draw a image using
Drawline by joining the co-ordinates.

I am successfull in doing that. But i want to save the drawn image as
image file any of the format.

The following code snippet is used to draw the image...

Sub subMarkPoint(ByVal PicBox As PictureBox)

Dim bmp As New Bitmap(PicBox.Width, PicBox.Height)
Dim gr As Graphics = Graphics.FromImage(bmp)

Dim i As Integer

For i = 0 To (UBound(arrx) - 1)
gr.DrawLine(New Pen(Color.Green), arrx(i + 1), arry(i +
1), arrx(i), arry(i))
Next

PicBox.Image = bmp

End Sub

This will draw the image in picturebox

in that arrx() and arry() values are loaded dynamically.

so i need some tips and code snippets to make my work finish.


Thanks in advance....

Ashok

.



Relevant Pages

  • Re: Save lines drawn in the picturebox as an lmage
    ... you need to draw to a bitmap's Graphics object: ... Dim g As Graphics = Graphics.FromImage ... > of a barcode) in the picturebox paint event. ...
    (microsoft.public.dotnet.languages.vb)
  • RE: TreeView multiple selections
    ... But with this behavior I can't draw a node to normal after selecting twice ... .Net2.0 has added the build-in support for custom-draw. ... rectangle based on your requirement. ... Dim focusPen As New Pen ...
    (microsoft.public.dotnet.general)
  • Re: Horizontal lines
    ... horizontal line at the bottom of the bottom control in a detail section of a ... subreport, add code to the On Print event of the section. ... Dim intBottom As Integer ... > draw a horizontal line for my subreport, no vertical lines involved, ...
    (microsoft.public.access.reports)
  • Re: Horizontal lines
    ... Now I'm trying to draw a horizontal line in code. ... rectangle "separating" the opportunities, ... Dim intPageHeadHeight As Integer ... >> Dim intPageHeadHeight As Integer ...
    (microsoft.public.access.reports)
  • Re: Horizontal lines
    ... to draw vertical lines at the intLeft position. ... > Dim intPageHeadHeight As Integer ... >>> Dim intPageHeadHeight As Integer ...
    (microsoft.public.access.reports)