Results 1 to 6 of 6

Thread: Printing Chr$(205)

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Apr 1999
    Location
    Ruinen, Drente, Netherlands
    Posts
    192

    Post

    I like to print a double line on the paper, like String$(80,205), but it won't work in VB (in TurboBasic it worked well). What can I do ?

    ------------------

  2. #2
    Addicted Member
    Join Date
    Feb 2000
    Posts
    224

    Post

    Did u try vbCrLf ????

  3. #3
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Post

    You must use a font that containes that character.

    Dim sOldFontName$
    sOldFontName = Printer.FontName
    Printer.FontName = "Terminal"
    Printer.Print String$(80, 205)
    Printer.FontName = sOldFontName
    'the rest of your print procedure
    Printer.EndDoc

    Good luck!


    ------------------
    Joacim Andersson
    [email protected]
    [email protected]
    www.YellowBlazer.com



  4. #4
    Hyperactive Member Juan Carlos Rey's Avatar
    Join Date
    Aug 1999
    Location
    Mendoza, Argentina
    Posts
    301

    Post

    You'll get more control (i.e. position, width, angles) with Line property:

    Printer1.Line (X1, Y1) - (X2, Y1)

    State it twice (with a slight different Y) for a double line.

    ------------------
    Improve your self-esteem.
    It's so easy even you can do it!

    [This message has been edited by Juan Carlos Rey (edited 02-06-2000).]

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Apr 1999
    Location
    Ruinen, Drente, Netherlands
    Posts
    192

    Post

    Thanks Joacim, I am using this and it works fine.
    Juan I think your way is also right, but how can I now where the coordinates must be before or after printing the text on the paper ?

    regards, K. Lensen


    ------------------

  6. #6
    Hyperactive Member Juan Carlos Rey's Avatar
    Join Date
    Aug 1999
    Location
    Mendoza, Argentina
    Posts
    301

    Post

    Hi, Kars. It's easy. You have a "CurrentY" property that let you know where you are.

    If you want to print a line say 50 twips after a line of text, do so:

    Printer.Line (X1, CurrentY + 50) - (X2, CurrentY + 50)


    ------------------
    Improve your self-esteem.
    It's so easy even you can do it!

    [This message has been edited by Juan Carlos Rey (edited 02-07-2000).]

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