Results 1 to 4 of 4

Thread: [2005] Best Strategy For Drawing a Point On A Graph

  1. #1

    Thread Starter
    Hyperactive Member neef's Avatar
    Join Date
    Dec 2001
    Location
    Boston
    Posts
    311

    [2005] Best Strategy For Drawing a Point On A Graph

    I have made a pretty fancy graph image in Photoshop and would like to use it as a background image of a Panel. That's easy enough but now I'm not sure how to place points marking data inside or over the background image. Whenever I draw a point it seems to be underneath the background image. When I erase the image the stuff I draw is there but I can't get the image and the creategraphics methods in Paint to work together.

    My question then is how can you, using creategraphics, draw over a background image? Is it better just to draw the graph with creategraphics members and trash the bitmap?

    Thanx!
    Intermediate Level Programmer Extraordinaire

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: [2005] Best Strategy For Drawing a Point On A Graph

    You don't use CreateGraphics at all, so you must being doing it wrong. Follow the Simple Drawing link in my signature to see how to draw on a control. I'd suggest using a PictureBox with its Image property set, rather than a Panel with its BackgroundImage set.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Hyperactive Member neef's Avatar
    Join Date
    Dec 2001
    Location
    Boston
    Posts
    311

    Re: [2005] Best Strategy For Drawing a Point On A Graph

    I fixed this using e.graphics. I was a little rusty after a long layoff from programming.

    Thanx!
    Intermediate Level Programmer Extraordinaire

  4. #4
    Frenzied Member obi1kenobi's Avatar
    Join Date
    Aug 2007
    Posts
    1,091

    Re: [2005] Best Strategy For Drawing a Point On A Graph

    You should mark the thread resolved if you require no further assistance... Keeps the forums tidy Glad to see you've solved your problem. Cheers!
    Please rate helpful ppl's posts. It's the best 'thank you' you can give

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width