Re: PictureBox change fore color

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



"Konstantin." <Konstantin. @discussions.microsoft.com> wrote in message
news:F4E963B8-56E6-492F-B8A3-0B94A86DFC9A@xxxxxxxxxxxxxxxx
> Hi!!
> I'm developing a math (ray tracing) application in VB6, and using .line
> method to draw between 100 and 100,000 lines in a picturebox. I need some
> of
> this lines be painted in a different color. I use
> picturebox.forecolor=RGB(255,0,0) in runtime but it just won't change the
> color the lines are painted!! What can I do?
>
> Thank you,
>
> Konstantin.

How are you drawing the lines? The Line method has an optional Color
argument....

Syntax
object.Line [Step] (x1, y1) [Step] - (x2, y2), [color], [B][F]

--
Ken Halter - MS-MVP-VB - http://www.vbsight.com
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Please keep all discussions in the groups..


.



Relevant Pages

  • Re: Form looses graphics after loosing focus
    ... The simple answer is that a PictureBox is designed to show and image. ... It is not meant to be a canvas on which to draw things. ... Prev by Date: ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Baffled or Buffered?
    ... >> I'm trying to draw these vertical lines using the picturebox ... Draw and erase lines on top of it ... type of routines. ... Prev by Date: ...
    (comp.lang.basic.visual.misc)
  • Re: PictureBox change fore color
    ... > method to draw between 100 and 100,000 lines in a picturebox. ... statement (and most other ancient VB graphics methods) has its own color ... Prev by Date: ...
    (microsoft.public.vb.controls)
  • Draw text on a image and save the result
    ... I try to draw text on a picturebox. ... The text appears but it is drawn on top of the picture. ... Prev by Date: ...
    (microsoft.public.dotnet.languages.vb)
  • with...end with and the picturebox
    ... this syntax ... With PictureBox ... Prev by Date: ...
    (microsoft.public.vb.general.discussion)