Results 1 to 4 of 4

Thread: How do I use divider lines in menus?

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 1999
    Posts
    65

    Post

    Like the ones that seperate the Save, and Save As, from Print, and Print Preview in paint.

    So how do I use them?

    ------------------
    "I'm carrying a Geometry book, but I'm not in Geometry...it's crazy...crazy man!"

  2. #2
    Guru Yonatan's Avatar
    Join Date
    Apr 1999
    Location
    Israel
    Posts
    892

    Post

    Create a menu item with the Menu Editor which you want to be a separator, and change its Caption to - (a single dash). VB will automatically make it a separator.

    ------------------
    Yonatan
    Teenage Programmer
    E-Mail: RZvika@netvision.net.il
    ICQ: 19552879



  3. #3

    Thread Starter
    Lively Member
    Join Date
    Oct 1999
    Posts
    65

    Post

    Sweet.

    Now how do I seperate the menu bar from the rest of the window using the same kind of line?

    ------------------
    "I'm carrying a Geometry book, but I'm not in Geometry...it's crazy...crazy man!"

  4. #4
    Guru Yonatan's Avatar
    Join Date
    Apr 1999
    Location
    Israel
    Posts
    892

    Post

    Create a Line control, name it Line1, set it's Index property to 0 (zero) and add this code:

    Private Sub Form_Load()
    Load Line1(1)
    Line1(1).Visible = True
    Line1(0).BorderColor = vbGrayText
    Line1(1).BorderColor = vb3DHighlight
    Call Form_Resize
    End Sub

    Private Sub Form_Resize()
    Line1(0).X1 = 0
    Line1(0).X2 = Width
    Line1(0).Y1 = 0
    Line1(0).Y2 = 0
    Line1(1).X1 = 0
    Line1(1).X2 = Width
    Line1(1).Y1 = ScaleX(1, vbPixels, ScaleMode)
    Line1(1).Y2 = ScaleX(1, vbPixels, ScaleMode)
    End Sub


    ------------------
    Yonatan
    Teenage Programmer
    E-Mail: RZvika@netvision.net.il
    ICQ: 19552879



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