Convert to string help

P

pokdbz

I'm using this statement:
ActiveCell.Offset(0, j + 2) = SAPReportSummaryArray(i, j)

SAPReportSummaryArray(i, j) = "7-11"
When I watch it stepping through its showing 7/11/2008. I need help forcing
this to text any ideas so it would show 7-11? ActiveCell.Offset(0, j + 2) is
the cell I want to insert it into.
 
G

Gary''s Student

In the most simple case:

Sub pok()
Range("A1").Value = "7-11"
End Sub

will put a date in the cell

Sub pok()
Range("A1").NumberFormat = "@"
Range("A1").Value = "7-11"
End Sub

will put the desired text in the cell.
 

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