Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Formatting Issue 1

Status
Not open for further replies.

TBOB

Technical User
Jun 22, 2002
65
0
0
US
Trying to format the variable LINENUM with the following code:

strLINETYPE = "W"
strLINENUM = "1234567"

Case 8
strLINENUM = Format(strLINENUM, "\A\B\C\D-" & strLINETYPE & "-@@@@@-@@")

This is resulting with this:
"ABCD-5-@@@@@-@@"

Should be this:
"ABCD-W-12345-67

I use this format with other LINENUM cases and the formatting works out fine. It only seems to have a problem when the LINETYPE is a "W". When I hover over strLINETYPE after it is initialized it is a "W". Any Suggestions?

Thanks,

Tony
 
I think you need another slash (\):
strLINENUM = Format(strLINENUM, "\A\B\C\D-[red]\[/red]" & strLINETYPE & "-@@@@@-@@")
 
Remou,

Your the man! That did it.

Thanks,

Tony
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top