G
Gus
Hi,
I have the following code in a form to limit the addition
of a field:
'SBB Less Old Jobs
Dim SBBInstallOJ As Double
Dim SBBRMROJ As Double
SBBInstallOJ = DSum
("[Install]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#")
SBBRMROJ = DSum
("[RMR]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#")
txtInstallOJS.Value = SBBInstallOJ
txtRMROJS.Value = SBBRMROJ
On this form I now must allow for two people and am trying
to add an IIF statement in so that I can select a persons
name from a combo box (there will never be more than two
names in this) on the same form (frmBonus). In
the "SBBInstallOJ" line to add this statement but it
doesn't work.
SBBInstallOJ = IIF(cboSalesManagerName = John Doe, DSum
("[Install]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#", DSum("[Install]", "tblSalesbwBranch", "[DateEntered]
< #01-Jun-04#",))
Any help would be greatly appreciated.
Thanks in advance,
Gus
I have the following code in a form to limit the addition
of a field:
'SBB Less Old Jobs
Dim SBBInstallOJ As Double
Dim SBBRMROJ As Double
SBBInstallOJ = DSum
("[Install]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#")
SBBRMROJ = DSum
("[RMR]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#")
txtInstallOJS.Value = SBBInstallOJ
txtRMROJS.Value = SBBRMROJ
On this form I now must allow for two people and am trying
to add an IIF statement in so that I can select a persons
name from a combo box (there will never be more than two
names in this) on the same form (frmBonus). In
the "SBBInstallOJ" line to add this statement but it
doesn't work.
SBBInstallOJ = IIF(cboSalesManagerName = John Doe, DSum
("[Install]", "tblSalesbwBranch", "[DateEntered] < #01-Apr-
02#", DSum("[Install]", "tblSalesbwBranch", "[DateEntered]
< #01-Jun-04#",))
Any help would be greatly appreciated.
Thanks in advance,
Gus