VB 6 problem

Oxaqata

Senior member
Jul 14, 2006
372
0
0
Does anyone know how I can add an empty line to a textbox through code. The only way I can think of is to add a string of empty characters but it doesnt work too well.
 

clamum

Lifer
Feb 13, 2003
26,256
406
126
You can use vbNewLine too which I believe is platform independent. For example, Windows uses a CR and LF, Mac uses CR (through version 9), and OS X and Unix/Linux use LF. I've never had a problem with using vbCrLf but I've began using vbNewLine instead.
 

Oxaqata

Senior member
Jul 14, 2006
372
0
0
Dont think im using this correctly. Should I just add this line to the code or EditBox.vbCrLf/vbNewLine?

Edit: Don't worry I got it, thanks for your help :)
 

Oxaqata

Senior member
Jul 14, 2006
372
0
0
A few more qustions :D

How can I make some sort of Code that automatically makes certain lines within a textbox bold, italic. underline, bigger/smaller etc..?

Also, whats the easiest/best way to print a document wihin the program?

Thanks
 

letdown427

Golden Member
Jan 3, 2006
1,594
1
0
To the best of my knowledge, the textbox font is uniform throughout, you can't have bits of it bold etc.

You'd have to go for multiple text boxes and have it jump to the next line when it reached the end or somesuch trickery.
 

BoberFett

Lifer
Oct 9, 1999
37,562
9
81
Use the RTF text box. It's a separate ActiveX control, but you can control the font the way you want.

As for printing, I suppose you could go find a text box control with formatting that supported automatic printing. Otherwise you'd have to use the printer object and print out everything on your own.