Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 244
Default Increase/decrease decimal code

Hi all,

I've been digging through the VBA functions in search of
an easy way to increase/decrease the number of decimal
places shown in a cell. The purpose would be so that I
could use a shortcut macro key instead of having to go up
to the toolbar every time.

So far I've had no luck. Short of manually retrieving and
modifying the cell's NumberFormat property, anyone know of
a simple way to accomplish this?

Thanks for any help!
Chris
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Increase/decrease decimal code

That is how you would do it. That is how it is set, so that is how you
would have to reset it.

--
Regards,
Tom Ogilvy

"Chris" wrote in message
...
Hi all,

I've been digging through the VBA functions in search of
an easy way to increase/decrease the number of decimal
places shown in a cell. The purpose would be so that I
could use a shortcut macro key instead of having to go up
to the toolbar every time.

So far I've had no luck. Short of manually retrieving and
modifying the cell's NumberFormat property, anyone know of
a simple way to accomplish this?

Thanks for any help!
Chris



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Increase/decrease decimal code

Chris,

Here's one way:

Const cDecreaseDecimal = 399
Const cIncreaseDecimal = 398
Application.CommandBars.FindControl(ID:=cIncreaseD ecimal).Execute


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chris" wrote in message
...
Hi all,

I've been digging through the VBA functions in search of
an easy way to increase/decrease the number of decimal
places shown in a cell. The purpose would be so that I
could use a shortcut macro key instead of having to go up
to the toolbar every time.

So far I've had no luck. Short of manually retrieving and
modifying the cell's NumberFormat property, anyone know of
a simple way to accomplish this?

Thanks for any help!
Chris



  #4   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Increase/decrease decimal code

Worked like a charm, many thanks!

-----Original Message-----
Chris,

Here's one way:

Const cDecreaseDecimal = 399
Const cIncreaseDecimal = 398
Application.CommandBars.FindControl

(ID:=cIncreaseDecimal).Execute


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chris" wrote in

message
...
Hi all,

I've been digging through the VBA functions in search of
an easy way to increase/decrease the number of decimal
places shown in a cell. The purpose would be so that I
could use a shortcut macro key instead of having to go

up
to the toolbar every time.

So far I've had no luck. Short of manually retrieving

and
modifying the cell's NumberFormat property, anyone know

of
a simple way to accomplish this?

Thanks for any help!
Chris



.

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
Increase & Decrease Decimal Place Aaron Excel Worksheet Functions 6 December 9th 08 01:27 AM
increase/decrease decimal cbfinancial Excel Worksheet Functions 2 April 10th 06 10:43 PM
% of increase or decrease Neil R Excel Discussion (Misc queries) 9 November 27th 05 03:13 AM
How do I set a cell that can increase but never decrease? Rich Excel Discussion (Misc queries) 2 November 2nd 05 06:04 PM
Value Increase/Decrease/No Change Michael Excel Worksheet Functions 1 November 5th 04 11:32 AM


All times are GMT +1. The time now is 02:32 AM.

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

About Us

"It's about Microsoft Excel"