Draw Line On Windows/Of The Form

Discussion in 'Archives' started by nuclear112, Jun 12, 2007.

Draw Line On Windows/Of The Form
  1. Unread #1 - Jun 12, 2007 at 3:20 AM
  2. nuclear112
    Joined:
    Jan 24, 2007
    Posts:
    62
    Referrals:
    0
    Sythe Gold:
    0

    nuclear112 Member
    Banned

    Draw Line On Windows/Of The Form

    Draw Line On Windows/Of The Form
    Does anyone know how to make it so that something draws a line on windows using the variables x1,x2,y1 and y2. e.g
    Code:
    drawLineWindows(x1,x2,y1,y2,color)
    Picture below for example.
    [​IMG]

    Thanks, Nuclear112
     
  3. Unread #2 - Jun 12, 2007 at 8:27 PM
  4. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

  5. Unread #3 - Jun 12, 2007 at 9:31 PM
  6. timk777
    Joined:
    Feb 19, 2007
    Posts:
    156
    Referrals:
    0
    Sythe Gold:
    0

    timk777 Active Member

    Draw Line On Windows/Of The Form

    Jazz, get your site to work with IE please =(
     
  7. Unread #4 - Jun 12, 2007 at 10:58 PM
  8. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

    nah, get firefox ^_^
    I might have to pull it apart... I'll take a look @ it now for ya since I have some free time

    EDIT: Hmm, I found the problem.. let me re-upload some pages and tell me YOUR results
     
  9. Unread #5 - Jun 13, 2007 at 4:51 AM
  10. nuclear112
    Joined:
    Jan 24, 2007
    Posts:
    62
    Referrals:
    0
    Sythe Gold:
    0

    nuclear112 Member
    Banned

    Draw Line On Windows/Of The Form

    Great script thanks... But can you make it so that I can make the line visible/not visible. I want to make it so that the line flashs twice then disappears...
     
  11. Unread #6 - Jun 13, 2007 at 5:14 AM
  12. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

    I'm leaving for work right now, but when I get home I'll see what I can do
     
  13. Unread #7 - Jun 13, 2007 at 12:25 PM
  14. Cruel__Machine
    Referrals:
    100

    Cruel__Machine Guest

    Draw Line On Windows/Of The Form

    Cool. Works for IE now. :D
     
  15. Unread #8 - Jun 13, 2007 at 3:30 PM
  16. nuclear112
    Joined:
    Jan 24, 2007
    Posts:
    62
    Referrals:
    0
    Sythe Gold:
    0

    nuclear112 Member
    Banned

    Draw Line On Windows/Of The Form

    Thanks Jazz :)
     
  17. Unread #9 - Jun 14, 2007 at 3:08 PM
  18. -------owned-------
    Joined:
    Jan 27, 2007
    Posts:
    1,225
    Referrals:
    0
    Sythe Gold:
    0

    -------owned------- Guru
    Banned

    Draw Line On Windows/Of The Form

    Are you Cruel? :p
     
  19. Unread #10 - Jun 14, 2007 at 10:27 PM
  20. T7 Press 7T
    Joined:
    Jun 14, 2007
    Posts:
    384
    Referrals:
    0
    Sythe Gold:
    0

    T7 Press 7T Forum Addict

    Draw Line On Windows/Of The Form

    Im just wondering but whats the point of a line drawer? on the pc window I meen...
     
  21. Unread #11 - Jun 15, 2007 at 12:21 AM
  22. nuclear112
    Joined:
    Jan 24, 2007
    Posts:
    62
    Referrals:
    0
    Sythe Gold:
    0

    nuclear112 Member
    Banned

    Draw Line On Windows/Of The Form

    Im going to make a macro and when the person selects the hwnd(window handle) that a box flashs around the hwnd.
     
  23. Unread #12 - Jun 15, 2007 at 12:22 AM
  24. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

    Lol, if you had said that, I could have given you a simpler way. let me make you an example, you'll like the results


    EDIT:


    http://jazz.cruels.net/ > Downloads > VB6 > Simple DrawRect Example

    That is what you want, all wrapped up in a bundle.

    The colour for the line is a negative of the colour you put in, such as vbgreen would be vbmagenta and vbmagenta would be vbgreen.
     
  25. Unread #13 - Jun 15, 2007 at 4:34 AM
  26. nuclear112
    Joined:
    Jan 24, 2007
    Posts:
    62
    Referrals:
    0
    Sythe Gold:
    0

    nuclear112 Member
    Banned

    Draw Line On Windows/Of The Form

    Thank you so much XD.
     
  27. Unread #14 - Jun 15, 2007 at 12:14 PM
  28. dark_vampire
    Joined:
    Jun 9, 2007
    Posts:
    155
    Referrals:
    0
    Sythe Gold:
    0

    dark_vampire Active Member

    Draw Line On Windows/Of The Form

    Good work
     
  29. Unread #15 - Jun 16, 2007 at 2:56 AM
  30. Darthatron
    Joined:
    May 22, 2006
    Posts:
    1,612
    Referrals:
    3
    Sythe Gold:
    0

    Darthatron Massive Troll
    Retired Sectional Moderator Visual Basic Programmers

    Draw Line On Windows/Of The Form

    Jazz, you can fix the color problem by inverting it...
    Code:
    InvertColor = &HFFFFFF - Color
    I think that does the job...
     
  31. Unread #16 - Jun 16, 2007 at 3:13 AM
  32. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

    No sir, even converting the long to a hex it wont work.
     
  33. Unread #17 - Jun 16, 2007 at 6:31 AM
  34. Darthatron
    Joined:
    May 22, 2006
    Posts:
    1,612
    Referrals:
    3
    Sythe Gold:
    0

    Darthatron Massive Troll
    Retired Sectional Moderator Visual Basic Programmers

    Draw Line On Windows/Of The Form

    Try downloading this project and you'll see what i mean. It works for me, so yeah... Sorry if I'm getting annoying. It's just the project, no viruses. :)

    Added an updated version of yours.
     

    Attached Files:

  35. Unread #18 - Jun 16, 2007 at 7:24 AM
  36. Jazz00006
    Joined:
    Aug 26, 2005
    Posts:
    807
    Referrals:
    0
    Sythe Gold:
    0

    Jazz00006 Apprentice
    Visual Basic Programmers

    Draw Line On Windows/Of The Form

    Hmmm, I used a similar method (format() rather then right()). It depends on the window you select...

    If I select the visual basic form with the code on it, it's green, same with my taskbar. But I if I select an explorer window, it is magenta. So your idea did work the first time.

    Nice work, I'll update the code on my site with your edited version... but you declared "Color" as a global, I take marks off for that :D
     
  37. Unread #19 - Jun 16, 2007 at 9:11 AM
  38. Darthatron
    Joined:
    May 22, 2006
    Posts:
    1,612
    Referrals:
    3
    Sythe Gold:
    0

    Darthatron Massive Troll
    Retired Sectional Moderator Visual Basic Programmers

    Draw Line On Windows/Of The Form

    Aww darn, I was looking to please. :(

    Just remembered why i declared it as Global, so the user can choose a color from the form (with the proper function), instead of just being able to edit it with the code. ;)
     
< what to check for | buying lvl 40-55 str pure >

Users viewing this thread
1 guest


 
 
Adblock breaks this site