Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 28
Default FORMAT CELLS

HI,
I WANT SOME CELLS TO BE TEXT FORMATED.

ActiveSheet.Cells(3, 14).Text = "3/4"
ActiveSheet.Cells(3, 14).NumberFormat = "General"

THE ABOVE CODE DOES NOT DO WHAT IT IS SUPPOSED TO DO.
HOW CAN IT BE SOLVED?

THANKS.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 205
Default FORMAT CELLS

Change .Text to .Value

Best regards

John
"ermeko" wrote in message
...
HI,
I WANT SOME CELLS TO BE TEXT FORMATED.

ActiveSheet.Cells(3, 14).Text = "3/4"
ActiveSheet.Cells(3, 14).NumberFormat = "General"

THE ABOVE CODE DOES NOT DO WHAT IT IS SUPPOSED TO DO.
HOW CAN IT BE SOLVED?

THANKS.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 28
Default FORMAT CELLS

THE TEXT IS FORMATED AS DATEVALUE. BUT I DON'T WANT THE TEXT INSERTED TO BE
CONVERTED INTO THE DATE. AND I DON'T WANT TO USE EXCEL TOOLS.
THANKS

"John" wrote:

Change .Text to .Value

Best regards

John
"ermeko" wrote in message
...
HI,
I WANT SOME CELLS TO BE TEXT FORMATED.

ActiveSheet.Cells(3, 14).Text = "3/4"
ActiveSheet.Cells(3, 14).NumberFormat = "General"

THE ABOVE CODE DOES NOT DO WHAT IT IS SUPPOSED TO DO.
HOW CAN IT BE SOLVED?

THANKS.




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default FORMAT CELLS

ActiveSheet.Cells(3, 14).NumberFormat = "General"
ActiveSheet.Cells(3, 14).Value = "'3/4"


Note that the single quote at the beginning of your string will preserve it
as text - it will not display.


--
Regards,
Tom Ogilvy


"ermeko" wrote in message
...
THE TEXT IS FORMATED AS DATEVALUE. BUT I DON'T WANT THE TEXT INSERTED TO

BE
CONVERTED INTO THE DATE. AND I DON'T WANT TO USE EXCEL TOOLS.
THANKS

"John" wrote:

Change .Text to .Value

Best regards

John
"ermeko" wrote in message
...
HI,
I WANT SOME CELLS TO BE TEXT FORMATED.

ActiveSheet.Cells(3, 14).Text = "3/4"
ActiveSheet.Cells(3, 14).NumberFormat = "General"

THE ABOVE CODE DOES NOT DO WHAT IT IS SUPPOSED TO DO.
HOW CAN IT BE SOLVED?

THANKS.






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 28
Default FORMAT CELLS

HI TOM,
THIS IS THE SECOND TIME YOU HELP ME.
THANK YOU VERY MUCH

"Tom Ogilvy" wrote:

ActiveSheet.Cells(3, 14).NumberFormat = "General"
ActiveSheet.Cells(3, 14).Value = "'3/4"


Note that the single quote at the beginning of your string will preserve it
as text - it will not display.


--
Regards,
Tom Ogilvy


"ermeko" wrote in message
...
THE TEXT IS FORMATED AS DATEVALUE. BUT I DON'T WANT THE TEXT INSERTED TO

BE
CONVERTED INTO THE DATE. AND I DON'T WANT TO USE EXCEL TOOLS.
THANKS

"John" wrote:

Change .Text to .Value

Best regards

John
"ermeko" wrote in message
...
HI,
I WANT SOME CELLS TO BE TEXT FORMATED.

ActiveSheet.Cells(3, 14).Text = "3/4"
ActiveSheet.Cells(3, 14).NumberFormat = "General"

THE ABOVE CODE DOES NOT DO WHAT IT IS SUPPOSED TO DO.
HOW CAN IT BE SOLVED?

THANKS.







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I format cells to show date in Australian not US format? Kevin B[_2_] Excel Worksheet Functions 1 May 12th 08 04:17 AM
how do i format a cell based on format of a range of cells? Chris Hardick Excel Discussion (Misc queries) 2 April 3rd 06 08:54 AM
want format cells alignment not format cells font style Jeannie Bean Excel Discussion (Misc queries) 2 February 10th 06 09:31 AM
Cells won't convert to number format, even after format/cells/num. scottr Excel Discussion (Misc queries) 5 April 12th 05 11:02 PM
When I select "format cells", the format dialog box does not disp. Andy S. Excel Worksheet Functions 2 November 23rd 04 03:49 AM


All times are GMT +1. The time now is 04:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"