I redid your code, adding indents so that I could see where it might be
having problems. My guess is that your line "IF
PART.CHECKBOX10=false..." does not first check for the existence of the
part. You seem to check for the existence of a part record before that,
not sure why this time you aren't.
Find First ttPODetailwhere ttPODetail.RowMod= "A" no-error.
If available ttPODetailthen do:
find first part where part.company=
ttPODetail.Companyand Part.partnum= ttPODetail.PartNumno-lock no-error.
If not available part then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable
part?'"}.
end.
If available Part then do:
If ttpodetail.taxable= True then return.
end.
If ttpodetail.taxable= false then do:
If part.checkbox10 = False then do: ***RIGHT HERE
MAYBE***
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable
part?'"}.
end.
If part.checkbox10 = True then do:
assign
ttpodetail.taxable= part.checkbox10.
{lib/PublishInfoMsg.i&InfoMsg= "'Taxable status has been updated.'"}.
end.
end.
end.
end.
From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf
Of melissa hietala
Sent: Wednesday, April 14, 2010 6:37 PM
To: vantage@yahoogroups.com
Subject: [Vantage] BPM Code Question
Hello All,
I am attempting to create a pre-processing BPM on the PO.Update method.
I am placing the following code as a condition under the "Advanced"
button. When I create a new PO Line & attempt to save the record, the
BPM should launch. I am getting inconsistent results and a variety of
error messages such as "Cannot find the row in the database" Can anyone
find something wrong with the code below?
Thanks,
Dustin Biniek
Find First ttPODetailwhere ttPODetail.RowMod= "A" no-error.
If available ttPODetailthen do:
find first part where part.company= ttPODetail.Companyand Part.partnum=
ttPODetail.PartNumno-lock no-error.
If not available part then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable part?'"}.
end.
If available Part then do:
If ttpodetail.taxable= True then return.
end.
If ttpodetail.taxable= false then do:
If part.checkbox10 = False then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable part?'"}.
end.
If part.checkbox10 = True then do:
assign ttpodetail.taxable= part.checkbox10.
{lib/PublishInfoMsg.i&InfoMsg= "'Taxable status has been updated.'"}.
end.
end.
end.
[Non-text portions of this message have been removed]
[Non-text portions of this message have been removed]
having problems. My guess is that your line "IF
PART.CHECKBOX10=false..." does not first check for the existence of the
part. You seem to check for the existence of a part record before that,
not sure why this time you aren't.
Find First ttPODetailwhere ttPODetail.RowMod= "A" no-error.
If available ttPODetailthen do:
find first part where part.company=
ttPODetail.Companyand Part.partnum= ttPODetail.PartNumno-lock no-error.
If not available part then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable
part?'"}.
end.
If available Part then do:
If ttpodetail.taxable= True then return.
end.
If ttpodetail.taxable= false then do:
If part.checkbox10 = False then do: ***RIGHT HERE
MAYBE***
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable
part?'"}.
end.
If part.checkbox10 = True then do:
assign
ttpodetail.taxable= part.checkbox10.
{lib/PublishInfoMsg.i&InfoMsg= "'Taxable status has been updated.'"}.
end.
end.
end.
end.
From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf
Of melissa hietala
Sent: Wednesday, April 14, 2010 6:37 PM
To: vantage@yahoogroups.com
Subject: [Vantage] BPM Code Question
Hello All,
I am attempting to create a pre-processing BPM on the PO.Update method.
I am placing the following code as a condition under the "Advanced"
button. When I create a new PO Line & attempt to save the record, the
BPM should launch. I am getting inconsistent results and a variety of
error messages such as "Cannot find the row in the database" Can anyone
find something wrong with the code below?
Thanks,
Dustin Biniek
Find First ttPODetailwhere ttPODetail.RowMod= "A" no-error.
If available ttPODetailthen do:
find first part where part.company= ttPODetail.Companyand Part.partnum=
ttPODetail.PartNumno-lock no-error.
If not available part then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable part?'"}.
end.
If available Part then do:
If ttpodetail.taxable= True then return.
end.
If ttpodetail.taxable= false then do:
If part.checkbox10 = False then do:
{lib/PublishInfoMsg.i&InfoMsg= "'Is this a taxable part?'"}.
end.
If part.checkbox10 = True then do:
assign ttpodetail.taxable= part.checkbox10.
{lib/PublishInfoMsg.i&InfoMsg= "'Taxable status has been updated.'"}.
end.
end.
end.
[Non-text portions of this message have been removed]
[Non-text portions of this message have been removed]