Made it, but it only applies to line details with SN in [SOShipLineSplit.LotSerialNbr] and gets error when the DR I pick up has serial number from [SOShipLine.LotSerialNbr]. Been trying to play around this formula:
=IIf(IsNull([SOShipLine.LotSerialNbr], Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc]),'SN: ' + [SOShipLineSplit.LotSerialNbr],[SOShipLine.TranDesc] +'{br}'+ 'SN: ' + [SOShipLineSplit.LotSerialNbr])
This is the error,
This is the source of SN from details tab,
While this is where I am getting SN when sn from details tab is <split>,
Can somebody see where I should change something here, please? Thanks!
To be more precised, my formula only works with <split> SerialNbr
And with SerialNbrs already available in the details tab, it gets error.
=IIf(IsNull([SOShipLine.LotSerialNbr], Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc]),'SN: ' + [SOShipLineSplit.LotSerialNbr],[SOShipLine.TranDesc] +'{br}'+ 'SN: ' + [SOShipLineSplit.LotSerialNbr])
Can anybody see what is wrong in my formula? Thanks!
try =IIf(IsNull([SOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(IsNull(sSOShipLine.LotSerialNbr], Prev( SOShipLine.TranDesc])=eSOShipLine.TranDesc]),'SN: ' + :SOShipLineSplit.LotSerialNbr],lSOShipLine.TranDesc] +'{br}'+ 'SN: ' + :SOShipLineSplit.LotSerialNbr]), bSOShipLine.TranDesc])
try =IIf(IsNull([SOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(IsNull(sSOShipLine.LotSerialNbr], Prev( SOShipLine.TranDesc])=eSOShipLine.TranDesc]),'SN: ' + :SOShipLineSplit.LotSerialNbr],lSOShipLine.TranDesc] +'{br}'+ 'SN: ' + :SOShipLineSplit.LotSerialNbr]), bSOShipLine.TranDesc])
Thank you sir, but I think got the same error. What do you think is the problem?
try =IIf(IsNull([SOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(IsNull(sSOShipLine.LotSerialNbr], Prev( SOShipLine.TranDesc])=eSOShipLine.TranDesc]),'SN: ' + :SOShipLineSplit.LotSerialNbr],lSOShipLine.TranDesc] +'{br}'+ 'SN: ' + :SOShipLineSplit.LotSerialNbr]), bSOShipLine.TranDesc])
Thank you sir, but I think got the same error. What do you think is the problem?
Pls note, this works with SN from SOShipLineSplit also but gets error when SN is directly from details tab. Thank you
I am not so familiar with inventory module but seems SOShipLine.LotSerialNbr is a binary field. Try
=IIf(IsNull((SOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(Prev(fSOShipLine.TranDesc])=DSOShipLine.TranDesc]),'SN: ' + NSOShipLineSplit.LotSerialNbr],aSOShipLine.TranDesc] +'{br}'+ 'SN: ' + NSOShipLineSplit.LotSerialNbr]), NSOShipLine.TranDesc])
I am not so familiar with inventory module but seems SOShipLine.LotSerialNbr is a binary field. Try
=IIf(IsNull((SOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(IsNull(ISOShipLineSplit.LotSerialNbr], Prev(,SOShipLine.TranDesc])=DSOShipLine.TranDesc]),'SN: ' + NSOShipLineSplit.LotSerialNbr],aSOShipLine.TranDesc] +'{br}'+ 'SN: ' + NSOShipLineSplit.LotSerialNbr]), NSOShipLine.TranDesc])
Sad to say it also doesn’t work Sir, got the same error but for both getting DR with SN from SOShipLineSplit and SOShipLine : (
I edited the formula after I posted, did you get the last one and make sure to fix single quotes as I am typing on iPhone
=IIf(IsNull(lSOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(Prev(ISOShipLine.TranDesc])=nSOShipLine.TranDesc]),'SN: ' + SSOShipLineSplit.LotSerialNbr],iSOShipLine.TranDesc] +'{br}'+ 'SN: ' + SSOShipLineSplit.LotSerialNbr]), lSOShipLine.TranDesc])
I see some single quotations I typed are wrong
I edited the formula after I posted, did you get the last one and make sure to fix single quotes as I am typing on iPhone
=IIf(IsNull(lSOShipLineSplit.LotSerialNbr], '’)<>'’, IIf(Prev(ISOShipLine.TranDesc])=nSOShipLine.TranDesc]),'SN: ' + SSOShipLineSplit.LotSerialNbr],iSOShipLine.TranDesc] +'{br}'+ 'SN: ' + SSOShipLineSplit.LotSerialNbr]), lSOShipLine.TranDesc])
Yes sir I’m changing the single quotes everytime. Now I get a syntax error tho : ( whereelse could I be wrong?
Can you copy your edited formula here?
Can you copy your edited formula here?
=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc]),'SN: ' + [SOShipLineSplit.LotSerialNbr],[SOShipLine.TranDesc] + '{br}' + 'SN: ' + [SOShipLineSplit.LotSerialNbr]), [SOShipLine.TranDesc])
=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc],'SN: ' + [SOShipLineSplit.LotSerialNbr],[SOShipLine.TranDesc] + '{br}' + 'SN: ' + [SOShipLineSplit.LotSerialNbr]), [SOShipLine.TranDesc])
extra closing bracket before first SN
=IIf(IsNull([SOShipLineSplit.LotSerialNbr], '')<>'', IIf(Prev([SOShipLine.TranDesc])=[SOShipLine.TranDesc],'SN: ' + [SOShipLineSplit.LotSerialNbr],[SOShipLine.TranDesc] + '{br}' + 'SN: ' + [SOShipLineSplit.LotSerialNbr]), [SOShipLine.TranDesc])
extra closing bracket before first SN
Oh, I saw it! Thank you very very very much sir @aaghaei ! Now I will try to understand how this works. Big thanks! Really helped me!