My post disappeared - date format problem

  • Thread starter Thread starter Coleen
  • Start date Start date
C

Coleen

Hi all :-)

My post on weird date formatting disappeared from my list, so if this a duplicate post, I apologize.

I'm having trouble getting a date to format as just "MM/dd"

I don't care what the year is, I get that information first, then need to format the data as MM/dd to look for the Month and day to check if it is a Holiday. If it is a Holiday, and falls on a Monday (I can get the dddd to format just fine!), then I need to make the due date fall on the Tuesday after the Holiday. I've tried:

ls_due_dt = ld_due_dt.ToString() then, using
String.Format("MM/dd", ls_due_dt)

I've also tried Format(ls_due_dt, "MM/dd") which just gives me a literal string of "MM/dd". Any suggestions? TIA

Coleen
 
Hi,

Me.Text = Now.ToString("MM/dd")



Ken

------------------

Hi all :-)

My post on weird date formatting disappeared from my list, so if this a duplicate post, I apologize.

I'm having trouble getting a date to format as just "MM/dd"

I don't care what the year is, I get that information first, then need to
format the data as MM/dd to look for the Month and day to check if it is a
Holiday. If it is a Holiday, and falls on a Monday (I can get the dddd to
format just fine!), then I need to make the due date fall on the Tuesday
after the Holiday. I've tried:
ls_due_dt = ld_due_dt.ToString() then, using
String.Format("MM/dd", ls_due_dt)

I've also tried Format(ls_due_dt, "MM/dd") which just gives me a literal
string of "MM/dd". Any suggestions? TIA
engine supports Post Alerts, Ratings, and Searching.
 
Thanks for the help. I will try that, to see if it will work for me :-)

I finally got the date to format using:

ls_due_dt = Format(ld_due_dt, "dd-MMMM")

This works, it's just more wordy when writing the code I have to use "01-January" instead of "01/01"
 
Back
Top