L
Luna Saisho
Hiya!
I'm trying to set something up to help one of our folks track our shipments,
and I would like it to look on another subform to see what's going on, but I
keep getting errors.
So basically, this form has two subforms. One to display contact
information for the plant we're shipping to as chosen by a combo box on the
main form, and another subform that lets him enter the specifics of that
shipment, PO #, ship date and type, etc. The number of days to ship via Rail
or Over the Road (OTR) are in the first subform and in a different table,
from the second subform, as the second table holds shipment info related to
the main table. The purpose is to take the ship date and add however many
days as appropriate, which are different from different locations, and by
rail takes just forever!
So I try putting in this line in the Receive Date area on the form:
=IIf([ShipType]='OTR',[RecvDate]=[RecvDate]+[Forms]![Form-Main_Sub-LocationInfo].[OTR],[Forms]![Form-Main_Sub-LocationInfo].[Rail])
And it's fine until I try to use it. I have it use the On Enter event, so
it will react to the newly entered ship date, and get the error: "The
expression On Enter you entered as the event property setting produced the
following error: The object you referenced in the Visual Basic procedure as
an OLE object isn't an OLE object." It also changes the expression to:
=IIf([ShipType]='OTR',[RecvDate]=[RecvDate]+Forms![Form-Main_Sub-LocationInfo].OTR,Forms![Form-Main_Sub-LocationInfo].Rail)
Note that it took out a lot of the []'s. I also tried using double quotes
around the first OTR instead of apostrophes.
I've referenced another form's values before in another DV with no problem
by putting [Forms]![form name].[referenced field] and didn't have this as an
issue.
Does anyone have a possible correction for this, or another method? It
would be GREATLY appreciated.
Thanks!!
Steph
I'm trying to set something up to help one of our folks track our shipments,
and I would like it to look on another subform to see what's going on, but I
keep getting errors.
So basically, this form has two subforms. One to display contact
information for the plant we're shipping to as chosen by a combo box on the
main form, and another subform that lets him enter the specifics of that
shipment, PO #, ship date and type, etc. The number of days to ship via Rail
or Over the Road (OTR) are in the first subform and in a different table,
from the second subform, as the second table holds shipment info related to
the main table. The purpose is to take the ship date and add however many
days as appropriate, which are different from different locations, and by
rail takes just forever!
So I try putting in this line in the Receive Date area on the form:
=IIf([ShipType]='OTR',[RecvDate]=[RecvDate]+[Forms]![Form-Main_Sub-LocationInfo].[OTR],[Forms]![Form-Main_Sub-LocationInfo].[Rail])
And it's fine until I try to use it. I have it use the On Enter event, so
it will react to the newly entered ship date, and get the error: "The
expression On Enter you entered as the event property setting produced the
following error: The object you referenced in the Visual Basic procedure as
an OLE object isn't an OLE object." It also changes the expression to:
=IIf([ShipType]='OTR',[RecvDate]=[RecvDate]+Forms![Form-Main_Sub-LocationInfo].OTR,Forms![Form-Main_Sub-LocationInfo].Rail)
Note that it took out a lot of the []'s. I also tried using double quotes
around the first OTR instead of apostrophes.
I've referenced another form's values before in another DV with no problem
by putting [Forms]![form name].[referenced field] and didn't have this as an
issue.
Does anyone have a possible correction for this, or another method? It
would be GREATLY appreciated.
Thanks!!
Steph