Negative Column ????

D

DB

I'm trying to work something out and I am trying to find out if something is
possible...

Basically I do the losses and gains at work for various stocks - I manually
work out the losses and gains, recording them on a weekly basis.

The format is as follows.......

A B C
D E
Date Loss Gain
Net Result this week Result to Date
1
1/7/07 -50.00 -26.00 -
-26.00
2 8/7/07 -100.00 170.00
100.00 74.00
3
4
5
6
7
8
9

Is there a way that can treat the whole B column as Negative, rather than
having to input using a minus (-) sign .

I know it is a tiny problem - but is it possible ?

Many Thanks

DB:)
 
T

T. Valko

Do you mean that you want to enter 100 and have it automatically convert
to -100?

Will *every* number entered in column B be negative?
 
G

Gord Dibben

If Biff is correct about all of B being negative..............Jumping in here
with event code to make sure all entries in column B are negative no matter how
entered.

Private Sub Worksheet_Change(ByVal Target As Range)
Const WS_RANGE As String = "A:A"
Dim cell As Range

On Error GoTo ws_exit:
Application.EnableEvents = False
If Not Intersect(Target, Me.Range(WS_RANGE)) Is Nothing Then

If Left(Target.Value, 1) = "-" Then GoTo ws_exit
Target.Value = Target.Value * -1
cell.NumberFormat = "0;<0>"
End If
ws_exit:
Application.EnableEvents = True
End Sub


Gord Dibben MS Excel MVP
 
R

Rick Rothstein \(MVP - VB\)

Maybe it would be easier to think of the ***loss*** in positive terms and
enter it without the minus sign. That way, when you calculate with it, you
can subtract the value in the Loss column from whatever instead of adding it
(because it is negative).

Rick
 
V

Vasant Nanavati

Why not custom-format it with a leading minus sign, but then actually
subtract it? Of course, if others use the workbook, they will be mightily
confused. :)

[Red]-#,##0.00_)
_________________________________________________________________________
 
D

DB

Many Thanks for the info..

Im sorted out now..

DB :))






Vasant Nanavati said:
Why not custom-format it with a leading minus sign, but then actually
subtract it? Of course, if others use the workbook, they will be mightily
confused. :)

[Red]-#,##0.00_)
_________________________________________________________________________


DB said:
I'm trying to work something out and I am trying to find out if something
is
possible...

Basically I do the losses and gains at work for various stocks - I
manually
work out the losses and gains, recording them on a weekly basis.

The format is as follows.......

A B C D E
Date Loss Gain Net
Result this week Result to Date
1 1/7/07 -50.00 -26.00 - -26.00
2 8/7/07 -100.00 170.00 100.00
74.00
3
4
5
6
7
8
9

Is there a way that can treat the whole B column as Negative, rather than
having to input using a minus (-) sign .

I know it is a tiny problem - but is it possible ?

Many Thanks

DB:)
 

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