except for the save image thingy...
i got this code, but it just saves the control without the graphics i paint on top (with pen):
any ideas? pls?
ImageFormat img; Bitmap bt; Graphics screenShot;
private void button1_Click(object sender, EventArgs e)
{
if (saveFileDialog1.ShowDialog() == DialogResult.OK)
{
img = ImageFormat.Jpeg;
bt = new Bitmap(panel1.Width, panel1.Height, PixelFormat.Format16bppGrayScale);
screenShot = Graphics.FromImage(bt);
screenShot.CopyFromScreen(panel1.Location.X, panel1.Location.Y, panel1.Width, panel1.Height, panel1.Bounds.Size, CopyPixelOperation.SourceCopy);
}
bt.Save(saveFileDialog1.FileName, img);
}
FroglegPosted Apr 13, 2014, 4:16 PM
1: Create a bitmap to draw on for saving
2:Draw a white background to draw your lines on
3: The program runs thru the _lines collection and draws lines to coodinates and color
4:Your lines coordinates are stored in a new class called lines, which is created when the mouse button is released and added to a list of classes _lines
5:You can sort through that list to delete any line
To simplify -think of the line class as a one page of a book that is created on the fly
You can access or delete any page as you wish
Research - List of<>
Amit ZivPosted Apr 13, 2014, 10:28 AM
can u explain your code?
FroglegPosted Apr 13, 2014, 4:26 AM
You will find if you drag something over or minimize your form, the graphics will disappear
Even though I used panel_create graphics, it is only a temp dwg
check this out - save as jpg, print preview and undo function
Amit ZivPosted Apr 12, 2014, 6:06 PM
FroglegPosted Apr 12, 2014, 9:56 AM