Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread De Premor
You're welcome, We're happy to hear that your problem solved. But we have one problem here, 1/0/1900 is not a date, we will never meet that case in real world If i ask to you, What month before January ? That should be December, and that month is 12 not Zero ;-) Rgds, [dp] Pada 12/07/2013 5

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread srsev6
WOW!! Look at all these wonderful people coming to my aid. Thank you all so much for your help. DP this formula worked well except that it put a 1/0/1900 date in all my blank cells. I used part of Ashish's formulas to keep that from happening and now your code works perfectly. Private S

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread De Premor
Try this, this will search a whole used range in sheet, that will be very slow if you have a big data *Private Sub CommandButton1_Click()** **Dim Rng As Range** **For Each Rng In ActiveSheet.UsedRange** **If IsDate(Rng.Value) Then Rng.Value = Format(Rng.Value, "dd mmm ")**

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread srsev6
Thanks Ashish but the dates don't always fall in column D and are not always just two columns. How can I change this portion to search the entire sheet? I tried several options to no avail. For Each cl In Range("d2:d" & Range("d1048576").End(xlUp).Row) On Thursday, July 11, 2013 11:47

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread ashish koul
try this Sub sample() Dim cl As Range For Each cl In Range("d2:d" & Range("d1048576").End(xlUp).Row) cl.NumberFormat = "@" cl.Value = Application.WorksheetFunction.Text(cl.Value, "dd mmm ") Next End Sub see if it helps On Thu, Jul 11, 2013 at 9:43 PM, srsev6 wrote

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread srsev6
Thanks for your help Enrique. I have attached the file. In column "D" "Forecast_Date" is the column I want to apply the code to. I have added a command button I would like to click on to have the code run. If you double click in a cell under column "D" you will see there is a date stamp. N

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-11 Thread Anoop K Sharma
Please share your file mentioning all your requirements..I'll try.. On 7/8/13, srsev6 wrote: > Thank you Enrique. How do I set this up in a code to be able to use in a > command button? > > I am familiar with codes in visual basic but not an expert by any means in > writing them. > > > > > On We

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-08 Thread srsev6
Thank you Enrique. How do I set this up in a code to be able to use in a command button? I am familiar with codes in visual basic but not an expert by any means in writing them. On Wednesday, July 3, 2013 7:15:00 PM UTC-5, Enrique Martin wrote: > you can use = text(cell,"dd mmm "),

Re: $$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-03 Thread Anoop K Sharma
you can use = text(cell,"dd mmm "), this will give time in text format. On Thu, Jul 4, 2013 at 3:17 AM, srsev6 wrote: > Hi all, > > I have already posted this once but can not locate it so I apologize for > the duplicate post. > > > I hope someone can answer my question. I run dates out of

$$Excel-Macros$$ Macro to remove a timestamp in a date

2013-07-03 Thread srsev6
Hi all, I have already posted this once but can not locate it so I apologize for the duplicate post. I hope someone can answer my question. I run dates out of a database which uses access. The dates I pull out have a timestamp. The timestamp hinders my formulas in my excel spreadsheet