#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Cell Formulas


Hello, What formula will allow me to input a number % in (B 2) to find
$25,000 or input a number $25,000 in (C 2) to find 10% in (B 2) without
erasing the cell's formulas?


A B C
1 Sales Price: $250,000
2 Down Payment: 10% 25,000.
3 1st Mortgage 80% 200,000.
4 2nd Mortgage 10% 25,000.


--
BRustigian
------------------------------------------------------------------------
BRustigian's Profile: http://www.excelforum.com/member.php...fo&userid=4345
View this thread: http://www.excelforum.com/showthread...hreadid=566873

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4,339
Default Cell Formulas

A cell either contains either a value OR a formula, not both. You will have
to use VBA to accomplish what you want.

Right click on the sheet tab, and copy/paste code below. Assumes that Sale
Price will always be in cell(1,"C").

Private Sub Worksheet_Change(ByVal Target As Range)

On Error GoTo wsexit
Application.EnableEvents = False

If Target.Column = 2 Then
Cells(Target.Row, 3).Value = Cells(1, "C") * Target.Value
Else
If Target.Column = 3 Then
Cells(Target.Row, 2).Value = Target.Value / Cells(1, "C")
End If
End If
wsexit:
Application.EnableEvents = True
End Sub
"BRustigian" wrote:


Hello, What formula will allow me to input a number % in (B 2) to find
$25,000 or input a number $25,000 in (C 2) to find 10% in (B 2) without
erasing the cell's formulas?


A B C
1 Sales Price: $250,000
2 Down Payment: 10% 25,000.
3 1st Mortgage 80% 200,000.
4 2nd Mortgage 10% 25,000.


--
BRustigian
------------------------------------------------------------------------
BRustigian's Profile: http://www.excelforum.com/member.php...fo&userid=4345
View this thread: http://www.excelforum.com/showthread...hreadid=566873


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4,339
Default Cell Formulas

Sorry, missing info ...

Right click on the sheet tab, VIEW CODE and copy/paste code below ....


"Toppers" wrote:

A cell either contains either a value OR a formula, not both. You will have
to use VBA to accomplish what you want.

Right click on the sheet tab, and copy/paste code below. Assumes that Sale
Price will always be in cell(1,"C").

Private Sub Worksheet_Change(ByVal Target As Range)

On Error GoTo wsexit
Application.EnableEvents = False

If Target.Column = 2 Then
Cells(Target.Row, 3).Value = Cells(1, "C") * Target.Value
Else
If Target.Column = 3 Then
Cells(Target.Row, 2).Value = Target.Value / Cells(1, "C")
End If
End If
wsexit:
Application.EnableEvents = True
End Sub
"BRustigian" wrote:


Hello, What formula will allow me to input a number % in (B 2) to find
$25,000 or input a number $25,000 in (C 2) to find 10% in (B 2) without
erasing the cell's formulas?


A B C
1 Sales Price: $250,000
2 Down Payment: 10% 25,000.
3 1st Mortgage 80% 200,000.
4 2nd Mortgage 10% 25,000.


--
BRustigian
------------------------------------------------------------------------
BRustigian's Profile: http://www.excelforum.com/member.php...fo&userid=4345
View this thread: http://www.excelforum.com/showthread...hreadid=566873


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
Changing cell references in formulas to names and back again. Aaron Excel Discussion (Misc queries) 4 April 25th 06 11:12 PM
Urgent date/scheduling calc needed jct Excel Worksheet Functions 3 February 24th 06 01:36 AM
Dates of a Day for a month & year cell formulas mikeburg Excel Discussion (Misc queries) 2 December 29th 05 10:14 PM
cell color index comparison MINAL ZUNKE New Users to Excel 1 June 30th 05 07:11 AM
Copy cell format to cell on another worksht and update automatical kevinm Excel Worksheet Functions 21 May 19th 05 11:07 AM


All times are GMT +1. The time now is 11:09 AM.

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"