Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 93
Default Date Formatting

I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Date Formatting

Dim s As String
s = Application.WorksheetFunction.Text(Now, "mmmm")

--
Gary''s Student - gsnu200772


"bodhisatvaofboogie" wrote:

I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,651
Default Date Formatting

On Fri, 7 Mar 2008 06:54:04 -0800, bodhisatvaofboogie
wrote:

I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!



strbody = "text " & Format(Now(), "mmmm") & " text"

--ron
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Date Formatting

Try this...

strbody = "text " & MonthName(Month(Now)) & " text"

Rick


"bodhisatvaofboogie" wrote in
message ...
I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 93
Default Date Formatting

THanks for all the speedy results...NOW one step further can I make the date
Bold? and How do I do that?

strbody = "text " & MonthName(Month(Now)) & " text"


THANKS AGAIN!!!
"Rick Rothstein (MVP - VB)" wrote:

Try this...

strbody = "text " & MonthName(Month(Now)) & " text"

Rick


"bodhisatvaofboogie" wrote in
message ...
I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!







  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Date Formatting

If you are storing the value in a String variable (as your initial posting
showed), then no. Text has no attributes (such as Bold or Size), it only has
characters 'strung' one after the other. Things that display text *may* be
able to bold it, but it depends on what that display mechanism is (TextBox,
Excel cells, etc); also some file formats (Word, Rich Text Format, etc.)
allow text attributes to be stored along with the text, but those are files
that require specialized display mechanisms to read and show them.

Rick


"bodhisatvaofboogie" wrote in
message ...
THanks for all the speedy results...NOW one step further can I make the
date
Bold? and How do I do that?

strbody = "text " & MonthName(Month(Now)) & " text"


THANKS AGAIN!!!
"Rick Rothstein (MVP - VB)" wrote:

Try this...

strbody = "text " & MonthName(Month(Now)) & " text"

Rick


"bodhisatvaofboogie" wrote
in
message ...
I want to make this the Alpha Month instead of Numeric. For example

CStr(Month(Now)

This will give a result of the number 3

This is being used in the following way:

strbody = "text " & CStr(Month(Now) & " text"

Any help is appreciated. Thanks!!!






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
conditional formatting for cell date to equal today's date Sistereinstein Excel Worksheet Functions 2 September 10th 12 07:53 PM
Date formatting Stephanie Excel Discussion (Misc queries) 1 January 7th 10 04:47 PM
Date Formatting TheRiverT Excel Discussion (Misc queries) 4 August 7th 09 08:46 PM
Date formatting Sandy Excel Worksheet Functions 2 August 1st 07 09:32 PM
Date Colum Date Formatting & Validation Mike[_81_] Excel Programming 1 June 7th 04 01:59 AM


All times are GMT +1. The time now is 01:00 PM.

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"