Checking a Yes/No field for its value

I

IanB

I'm trying to set a value in a custom number field based on alternatives in
two other fields, and this is what I have tried so far:
IIf([Text18]="Business Activity",[Number10],[Number1]), where summary tasks
may or may not meet the test condition.
This works for tasks and milestones, apart from summary tasks where the
relevant value is not copied in - it's set to 0.

So how do I add in an additional test for summary tasks to set the value
explicitly?
Here's what I have tried so far ...
IIf( [Summary], truepart, falsepart )
IIf( [Summary]=True, truepart, falsepart )
IIf( [Summary]="Yes", truepart, falsepart )
IIf( [Summary]=-1, truepart, falsepart )

And compound conditions - do they work like Excel (eg AND(TestA,TestB,...))
or
or TestA AND TestB ?

Any advice welcome please!
 
J

John

IanB said:
I'm trying to set a value in a custom number field based on alternatives in
two other fields, and this is what I have tried so far:
IIf([Text18]="Business Activity",[Number10],[Number1]), where summary tasks
may or may not meet the test condition.
This works for tasks and milestones, apart from summary tasks where the
relevant value is not copied in - it's set to 0.

So how do I add in an additional test for summary tasks to set the value
explicitly?
Here's what I have tried so far ...
IIf( [Summary], truepart, falsepart )
IIf( [Summary]=True, truepart, falsepart )
IIf( [Summary]="Yes", truepart, falsepart )
IIf( [Summary]=-1, truepart, falsepart )

And compound conditions - do they work like Excel (eg AND(TestA,TestB,...))
or
or TestA AND TestB ?

Any advice welcome please!

IanB,
Applying a formula to summary tasks is very simple. In the customize
window where you elect to customize a spare field, toward the middle of
that window is an option to apply whatever formula you are creating to
summary and group tasks.

As far as compound conditions, yes you can nest and apply AND/OR logic
within a formula. Be careful though I've seen some users try to create
formulas that are so involved and complex they make your head spin. For
those cases I recommend the large complex formula be replaced with
multiple simple formulas in multiple fields and/or use VBA which is a
whole lot more versatile.

Hope this helps.

John
Project MVP
 
I

IanB

John,

Thanks - your comment led me to exactly what I needed !

Rgds,
Ian B

John said:
IanB said:
I'm trying to set a value in a custom number field based on alternatives in
two other fields, and this is what I have tried so far:
IIf([Text18]="Business Activity",[Number10],[Number1]), where summary tasks
may or may not meet the test condition.
This works for tasks and milestones, apart from summary tasks where the
relevant value is not copied in - it's set to 0.

So how do I add in an additional test for summary tasks to set the value
explicitly?
Here's what I have tried so far ...
IIf( [Summary], truepart, falsepart )
IIf( [Summary]=True, truepart, falsepart )
IIf( [Summary]="Yes", truepart, falsepart )
IIf( [Summary]=-1, truepart, falsepart )

And compound conditions - do they work like Excel (eg AND(TestA,TestB,...))
or
or TestA AND TestB ?

Any advice welcome please!

IanB,
Applying a formula to summary tasks is very simple. In the customize
window where you elect to customize a spare field, toward the middle of
that window is an option to apply whatever formula you are creating to
summary and group tasks.

As far as compound conditions, yes you can nest and apply AND/OR logic
within a formula. Be careful though I've seen some users try to create
formulas that are so involved and complex they make your head spin. For
those cases I recommend the large complex formula be replaced with
multiple simple formulas in multiple fields and/or use VBA which is a
whole lot more versatile.

Hope this helps.

John
Project MVP
.
 
J

John

IanB said:
John,

Thanks - your comment led me to exactly what I needed !

Rgds,
Ian B

Ian,
You're welcome and thanks for the feedback.

John
John said:
IanB said:
I'm trying to set a value in a custom number field based on alternatives
in
two other fields, and this is what I have tried so far:
IIf([Text18]="Business Activity",[Number10],[Number1]), where summary
tasks
may or may not meet the test condition.
This works for tasks and milestones, apart from summary tasks where the
relevant value is not copied in - it's set to 0.

So how do I add in an additional test for summary tasks to set the value
explicitly?
Here's what I have tried so far ...
IIf( [Summary], truepart, falsepart )
IIf( [Summary]=True, truepart, falsepart )
IIf( [Summary]="Yes", truepart, falsepart )
IIf( [Summary]=-1, truepart, falsepart )

And compound conditions - do they work like Excel (eg
AND(TestA,TestB,...))
or
or TestA AND TestB ?

Any advice welcome please!

IanB,
Applying a formula to summary tasks is very simple. In the customize
window where you elect to customize a spare field, toward the middle of
that window is an option to apply whatever formula you are creating to
summary and group tasks.

As far as compound conditions, yes you can nest and apply AND/OR logic
within a formula. Be careful though I've seen some users try to create
formulas that are so involved and complex they make your head spin. For
those cases I recommend the large complex formula be replaced with
multiple simple formulas in multiple fields and/or use VBA which is a
whole lot more versatile.

Hope this helps.

John
Project MVP
.
 

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