×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

VB - Changing font size with the Print# command

VB - Changing font size with the Print# command

VB - Changing font size with the Print# command

(OP)
Is it possible to change the font size and use the print# command.  Below you can sort of see what I want to do but it will not work.  What is the proper method to achieve this?

Open FileName For Append Access Write Lock Write As #1
  Font.Size = 16
  Print #1, "Print Line 1 at font size 16"
  Font.Size = 10
  Print #1, "Print Line 2 at font size 10"
  Close #1

RE: VB - Changing font size with the Print# command

The Print # statement is designed to store text as straight ASCII data, with date values stored in your local system short date format and numbers stored in an international format recognising local decimal separators.

To store text with font info you should look into the RichTextBox control, and its LoadFile and SaveFile statements, or you could hand-code the data as an HTML file.

Good Luck
johnwm
________________________________________________________
To get the best from these forums read FAQ731-376 before posting

UK steam enthusiasts: www.essexsteam.co.uk

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources