Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default IF statements across Worksheets

Great! I wanted the worksheet function not the VBA.

Thanks!!!

rgold

"Gord Dibben" wrote:

You have a mix of Excel worksheet function and VBA.

Do you want a worksheet function?

=IF(Rollup!D5=100,1,0)

VBA?

Sub goop()
With Sheets("Sheet2").Range("A1")
If Sheets("Rollup").Cells(5, 4) = 100 Then
.Value = 1
Else
.Value = 0
End If
End With
End Sub


Gord Dibben MS Excel MVP

On Wed, 18 Apr 2007 13:04:03 -0700, rgold
wrote:

Novice excel user here.

I am trying to use the insert function feature to insert a IF statement to
make a cell a 1 or 0 based on the value of a cell on a different worksheet.
The command I am using is as follows:

IF(Worksheets("RollUp").Cells(5,4) = 100, 1, 0)

I get an error at the Cells method.

Does anyone know the proper command to due this, or is it not possible.

thanks for the help!

rgold



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
If Statements sherobot Excel Worksheet Functions 0 March 28th 07 09:28 PM
IF Statements (Mutliple Statements) Deezel Excel Worksheet Functions 3 October 19th 06 06:13 AM
if statements, and statements Sum Limit and marking Excel Worksheet Functions 3 March 29th 06 03:25 PM
If statements... Neil Excel Worksheet Functions 2 October 20th 05 05:16 PM
if statements Tony Houston Excel Worksheet Functions 1 February 7th 05 04:04 PM


All times are GMT +1. The time now is 10:26 PM.

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"