writing to a cell

M

Michael Miazga

I know this HAS to be simple, but I can't find the command anywhere, driving
me crazy. I'm just trying to write to a cell the current date. only in
mm/dd/yyyy format. something like this, but it isn't right:

With curWks
.Range("J31").Clear
.Range("J31").Bold = True
.Range("J31").Text (Date)
End with
 
R

Richard Choate

Outside of the With statement:

ActiveCell = Format(Date, "mm/dd/yyyy")

Richard

I know this HAS to be simple, but I can't find the command anywhere, driving
me crazy. I'm just trying to write to a cell the current date. only in
mm/dd/yyyy format. something like this, but it isn't right:

With curWks
.Range("J31").Clear
.Range("J31").Bold = True
.Range("J31").Text (Date)
End with
 
R

Ryan Poth

Try replacing

..Range("J31").Text (Date)

with

..Range("J31").Value = Date

Regards,
Ryan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top