Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default Options in Cell

Is there a way to create;

A1=If(b10,b1, (otherwise 0 or user input)

so if b1=1 then a1=1, if b1=0 then a1 would = 0 or else a
value inputed by the user.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Options in Cell

If Range("B1").Value 0 Then
Range("A1").Value = Range("B1").Value
Else
Range("A1").Value = InputBox("Enter a value for Cell
A1.", , 0)
End If

Tod
-----Original Message-----
Is there a way to create;

A1=If(b10,b1, (otherwise 0 or user input)

so if b1=1 then a1=1, if b1=0 then a1 would = 0 or else

a
value inputed by the user.

.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,624
Default Options in Cell

Cells can't contain both a formula and user input.

You could simulate what you're after with an event macro. Put this in
the worksheet code module:

Private Sub Worksheet_Calculate()
With Range("B1")
If .Value 0 Then
Range("A1").Value = .Value
ElseIf .Value = 0 Then
With Range("A1")
If IsEmpty(.Value) Then .Value = 0
End With
Else
'?????
End If
End With
End Sub


In article ,
"Jon M." wrote:

Is there a way to create;

A1=If(b10,b1, (otherwise 0 or user input)

so if b1=1 then a1=1, if b1=0 then a1 would = 0 or else a
value inputed by the user.

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
tools options view window options Joe[_14_] Excel Discussion (Misc queries) 1 November 11th 09 04:08 PM
Code to copy the formulae of one cell to all the cell in the rangewith the specific cell and columnnumber changing Options Yuvraj Excel Discussion (Misc queries) 0 June 29th 09 11:20 AM
Cell options/combo box? Paulymon Excel Worksheet Functions 1 March 17th 06 06:43 PM
How can i create in one cell scroll-down different options? Francisco Excel Discussion (Misc queries) 1 March 10th 05 04:17 AM
Read options in more than one cell Jim Gentile Excel Worksheet Functions 5 December 7th 04 12:35 AM


All times are GMT +1. The time now is 05:46 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"