Results 1 to 6 of 6

Thread: UserControl style LineControl?

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Dec 2008
    Location
    Argentina
    Posts
    441

    UserControl style LineControl?

    hi, is possible create a "line control" with a UserControl?

    I mean their properties x1, y1, x2 and y2 and delete properties Top Left, Width and Height.
    and from the ide to use only two points of movement.
    Attached Images Attached Images  
    leandroascierto.com Visual Basic 6 projects

  2. #2

  3. #3
    VB6, XHTML & CSS hobbyist Merri's Avatar
    Join Date
    Oct 2002
    Location
    Finland
    Posts
    6,654

    Re: UserControl style LineControl?

    Yes, you can do it, somewhat. You can draw a black'n'white mask on usercontrol that gives you a flat transparency. Alpha transparency is not possible (easily). Having such a mask also has some limitations and the end result will be much heavier than the regular line control, so it doesn't really be very useful of a control. As, it won't work with two end point mechanism, it'll always be a rectangular shape that you draw with a usercontrol (so you have to have a property that tells which corners the control should account for).

    Anyway, define better what you're after and you'll probably get a bit better answers


    LaVolpe has AlphaImage usercontrol that is able to display alpha transparent PNG images, which also allows for rotation. Pretty cool stuff, the project is a bit big and complex though.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Dec 2008
    Location
    Argentina
    Posts
    441

    Re: UserControl style LineControl?

    I do not mean to be graphic, is very easy to draw a Line with alpha or solid, if windowless and transparent, that is not the question.

    the question is how to make a UserControl has only two points slecting as does the control line, two drag points, not four.
    is as shown in the image

    Greetings.
    leandroascierto.com Visual Basic 6 projects

  5. #5
    VB6, XHTML & CSS hobbyist Merri's Avatar
    Join Date
    Oct 2002
    Location
    Finland
    Posts
    6,654

    Re: UserControl style LineControl?

    Nope, you're not getting that. It would require hacking & testing all too much to get such a simple effect and working it in a stable way, you probably can't find anyone that skilled to work with VB6 anymore.

  6. #6
    New Member
    Join Date
    Sep 2006
    Posts
    1

    Re: UserControl style LineControl?

    I'm trying to make a user control like the one you want to make, because I need it to implement a class diagrams application. The best I could find is this:

    http://www.codeproject.com/KB/miscctrl/linetracker.aspx



    Take a look, it may help you. I going to try working with regions on the user control. The last one is a control for VB.NET.

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