Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Entering a value into a cell with a formula or by tying the value

I have a drop down list in E4 with the following options, Survival,
Operational, Transitional and Manual Entry.
Survival, Operational, & Transitional are tables with numerical values.
Should one of the tables be selected in E4 I would like a value from said
table to appear in D7 but should Manual Entry be selected in E4 I would like
to type a number into D7.
By using match and vlookup the value wanted from the respective tables are
in cells
Operational €“ K1
Survival €“ K2
Transitional €“ K3

Thanks
Andy G
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Entering a value into a cell with a formula or by tying the value

Once a table, say Survival, has been selected, do you want any value from the
Survival table to be displayed in D7 ? the first value ?, a random value ?,
or a specific value?
--
Gary''s Student - gsnu200746


"Andy G" wrote:

I have a drop down list in E4 with the following options, Survival,
Operational, Transitional and Manual Entry.
Survival, Operational, & Transitional are tables with numerical values.
Should one of the tables be selected in E4 I would like a value from said
table to appear in D7 but should Manual Entry be selected in E4 I would like
to type a number into D7.
By using match and vlookup the value wanted from the respective tables are
in cells
Operational €“ K1
Survival €“ K2
Transitional €“ K3

Thanks
Andy G

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Entering a value into a cell with a formula or by tying the va

The value from the Survival table will be in cell K2
The value from the Operational table will be in cell K1
The value from the Transitional table will be in cell K3
I am calculating the vertical centre of gravity of a vessel and want to
compare this with the allowable vertical centre of gravity for this vessel.
The allowable centre of gravity is found in the three tables above depending
on status of vessel.
Using the IF function in cell D7 it would be easy to extract the value of
allowable VCG (if only the tables were used) but should the vessel be damaged
the marine architects would supply a a new vertical centre of gravity which
would be typed into D7 overwriting the IF function!

Thanks
Andy G


"Gary''s Student" wrote:

Once a table, say Survival, has been selected, do you want any value from the
Survival table to be displayed in D7 ? the first value ?, a random value ?,
or a specific value?
--
Gary''s Student - gsnu200746


"Andy G" wrote:

I have a drop down list in E4 with the following options, Survival,
Operational, Transitional and Manual Entry.
Survival, Operational, & Transitional are tables with numerical values.
Should one of the tables be selected in E4 I would like a value from said
table to appear in D7 but should Manual Entry be selected in E4 I would like
to type a number into D7.
By using match and vlookup the value wanted from the respective tables are
in cells
Operational €“ K1
Survival €“ K2
Transitional €“ K3

Thanks
Andy G

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Entering a value into a cell with a formula or by tying the va

You can use a single cell for both a formula or a manual input with a macro:

Private Sub Worksheet_Change(ByVal Target As Range)
Dim s As String
If Intersect(Range("E4"), Target) Is Nothing Then Exit Sub
s = Target.Value
Application.EnableEvents = False
If s = "Survival" Then
Range("D7").Value = "=K2"
End If
If s = "Operational" Then
Range("D7").Value = "=K1"
End If
If s = "Transitional" Then
Range("D7").Value = "=K3"
End If
If s = "Manual" Then
MsgBox ("Please manually enter a value in cell D7")
End If
Application.EnableEvents = True
End Sub

To install the macro, right-click the tab name at the bottom of Excel,
select View Code and paste the macro into the VBA window. Then close the VBA
window.


--
Gary''s Student - gsnu200746


"Andy G" wrote:

The value from the Survival table will be in cell K2
The value from the Operational table will be in cell K1
The value from the Transitional table will be in cell K3
I am calculating the vertical centre of gravity of a vessel and want to
compare this with the allowable vertical centre of gravity for this vessel.
The allowable centre of gravity is found in the three tables above depending
on status of vessel.
Using the IF function in cell D7 it would be easy to extract the value of
allowable VCG (if only the tables were used) but should the vessel be damaged
the marine architects would supply a a new vertical centre of gravity which
would be typed into D7 overwriting the IF function!

Thanks
Andy G


"Gary''s Student" wrote:

Once a table, say Survival, has been selected, do you want any value from the
Survival table to be displayed in D7 ? the first value ?, a random value ?,
or a specific value?
--
Gary''s Student - gsnu200746


"Andy G" wrote:

I have a drop down list in E4 with the following options, Survival,
Operational, Transitional and Manual Entry.
Survival, Operational, & Transitional are tables with numerical values.
Should one of the tables be selected in E4 I would like a value from said
table to appear in D7 but should Manual Entry be selected in E4 I would like
to type a number into D7.
By using match and vlookup the value wanted from the respective tables are
in cells
Operational €“ K1
Survival €“ K2
Transitional €“ K3

Thanks
Andy G

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
Entering Formula - Cannot select cell as it is hidden by formula Jim Excel Worksheet Functions 0 March 25th 10 07:22 AM
Tying an imported graphic to a cell T.R. Young Excel Discussion (Misc queries) 0 October 5th 05 08:52 PM
Entering Sum formula into a cell Leo Heuser[_2_] Excel Programming 0 September 29th 03 07:55 PM
Entering Sum formula into a cell Bernard Liengme[_3_] Excel Programming 0 September 29th 03 04:11 PM
Entering Sum formula into a cell Don Guillett[_4_] Excel Programming 0 September 29th 03 03:55 PM


All times are GMT +1. The time now is 03:36 PM.

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"