View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Cells(1,1).Text

No, there is not worksheet function beyond Text, but you would only have to
enter the format the first time you write the formula, then copy it down.
Doesn't seem that difficult. Also, processing hundreds of cells, even
thousands would take much less than a minute on a modern machine using a for
loop - so not sure what your concern is there either. If you are doing

activecell.offset(1,0).Select
Selection.Value = 3

kind of code, then either remove the select statements and join the code or
use

Application.ScreenUpdating = False ' at the start

Application.ScreenUpdating = True ' at the end

--
Regards,
Tom Ogilvy


"Dave Martin" wrote in message
...
Using Excel 2000.
Is there any way to use a Worksheet function in Excel that mimics the VBA
funtion Cells(1,1).Text?

The =TEXT function requires a format argument. All I want is the contents
of the cell in its currently displayed format. I have spent hours trying

to
concatenate two columns one of which is a date. Excel insists on

converting
the date into its underlying value (eg, 36721.3) when it concatenates with
the contents of another cell.

This is a piece of cake in VBA using the .Text function, but I have

several
hundred cells I need to concatenate, so going through a For/Next loop to
convert all these would be a time consuming step. Any ideas from you
Wizards out there would be greatly appreciated.