Jump to content
Xtreme .Net Talk

Format$ - Named numeric formats


Recommended Posts

Guest bananafish
Posted

I am looking to format a number with leading spaces. ie I want to display 3 as " 3", 33 as " 3" and 333 as "333"

 

What is the Format$ predefined numeric format for this, I thought it was Format$(intX, "##0"), but that would return "3", "33" and "333"

 

I then tried Format$(intX, "000") but that gives "003", "033" and "333"

 

Any ideas?

Guest bananafish
Posted
I tried format$(intX, "@@@" - and all I got was "@@@" and not " 3"
Guest bananafish
Posted

Well, that didn't work.

 

Thanks for the help anyway.

 

I am using .Net btw - I know I should have posted in that forum - but I didn't check where I was before I posted - and decided the question was probably the same for vb6 and .net. Guess I was wrong.

 

Ive written a dinky little routine to do it now anyway.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...