Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 51
Default Concatenating Numbers & Text to create a String

I have Totals in a variable that I would like to print out in a string
formatted

Dim Total
Dim String

String = 'The total is " & Total

The result is The total is 9999.9

I want it to look like The total is $9,999.99

How do I format a varible when I am concatinating the Varible to a String.

Thanks
Dana

--
Message posted via http://www.officekb.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Concatenating Numbers & Text to create a String

String = "The total is " & format(total, "$#,##0.00")

"Fredriksson via OfficeKB.com" wrote:

I have Totals in a variable that I would like to print out in a string
formatted

Dim Total
Dim String

String = 'The total is " & Total

The result is The total is 9999.9

I want it to look like The total is $9,999.99

How do I format a varible when I am concatinating the Varible to a String.

Thanks
Dana

--
Message posted via http://www.officekb.com


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 51
Default Concatenating Numbers & Text to create a String

Thanks
Dave Peterson wrote:
String = "The total is " & format(total, "$#,##0.00")

I have Totals in a variable that I would like to print out in a string
formatted

[quoted text clipped - 15 lines]
--
Message posted via http://www.officekb.com



--
Message posted via http://www.officekb.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Extract numbers from a string of text Huber57 Excel Discussion (Misc queries) 0 May 27th 10 09:53 PM
Extract numbers from a string of text Mike H Excel Discussion (Misc queries) 0 May 27th 10 09:48 PM
Formula Text String: Formatting Text and Numbers? dj479794 Excel Discussion (Misc queries) 5 June 30th 07 12:19 AM
Create a 'text' string based on whether values appear in other cel Ben Excel Worksheet Functions 4 February 20th 07 10:05 AM
Concatenating a string and an integer [email protected] Excel Programming 2 April 5th 06 07:40 PM


All times are GMT +1. The time now is 06:06 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"