A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Negative numbers



 
 
Thread Tools Display Modes
  #1  
Old September 21st, 2008, 03:49 PM posted to microsoft.public.excel.worksheet.functions
Vercingetorix.XIII[_2_]
external usenet poster
 
Posts: 29
Default Negative numbers

Is there a way to make a number be a negative number when it is entered in? I
need to add a total of figures and have it subtract from another total.
  #2  
Old September 21st, 2008, 04:29 PM posted to microsoft.public.excel.worksheet.functions
David Biddulph
external usenet poster
 
Posts: 8,714
Default Negative numbers

Yes. Type in a minus sign - before the number.
--
David Biddulph

"Vercingetorix.XIII" wrote in
message ...
Is there a way to make a number be a negative number when it is entered
in? I
need to add a total of figures and have it subtract from another total.



  #3  
Old September 21st, 2008, 04:42 PM posted to microsoft.public.excel.worksheet.functions
Candicehkjc
external usenet poster
 
Posts: 2
Default Negative numbers

Selet the cell, then select format cells Select Custom and type -0. Then all
integer input with change to negative. e.g. type 123 will display -123.

"Vercingetorix.XIII" wrote:

Is there a way to make a number be a negative number when it is entered in? I
need to add a total of figures and have it subtract from another total.

  #4  
Old September 21st, 2008, 05:45 PM posted to microsoft.public.excel.worksheet.functions
David Biddulph
external usenet poster
 
Posts: 8,714
Default Negative numbers

And do you think that the arithmetic will treat that as a negative number as
the OP requested, Candice, or will it do the same as other formatting and
merely change the *display* of the number?
--
David Biddulph

"Candicehkjc" wrote in message
...
Selet the cell, then select format cells Select Custom and type -0. Then
all
integer input with change to negative. e.g. type 123 will display -123.

"Vercingetorix.XIII" wrote:

Is there a way to make a number be a negative number when it is entered
in? I
need to add a total of figures and have it subtract from another total.



  #5  
Old September 21st, 2008, 05:45 PM posted to microsoft.public.excel.worksheet.functions
Gord Dibben
external usenet poster
 
Posts: 20,252
Default Negative numbers

That will "display" only.

The number will still be positive.


Gord Dibben MS Excel MVP

On Sun, 21 Sep 2008 08:42:01 -0700, Candicehkjc
wrote:

Selet the cell, then select format cells Select Custom and type -0. Then all
integer input with change to negative. e.g. type 123 will display -123.

"Vercingetorix.XIII" wrote:

Is there a way to make a number be a negative number when it is entered in? I
need to add a total of figures and have it subtract from another total.


  #6  
Old September 21st, 2008, 05:50 PM posted to microsoft.public.excel.worksheet.functions
Gord Dibben
external usenet poster
 
Posts: 20,252
Default Negative numbers

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 1 Then
On Error GoTo endit
Application.EnableEvents = False
Target.Value = Target.Value * -1
End If
endit:
Application.EnableEvents = True
End Sub

This is sheet event code. Right-click on the sheet tab and "View Code"

Copy/paste the code into that module.

Alt + q to return to the Excel window.

Enter any numbers in column A as positive and they will become negative.


Gord Dibben MS Excel MVP


On Sun, 21 Sep 2008 07:49:00 -0700, Vercingetorix.XIII
wrote:

Is there a way to make a number be a negative number when it is entered in? I
need to add a total of figures and have it subtract from another total.


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


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


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