AnsweredAssumed Answered

What cause portal record to disappear after saving or going to another record?

Question asked by pleiades on Oct 16, 2017
Latest reply on Oct 17, 2017 by philmodjunk

Hi,

 

I'm trying to duplicate records and its portal records ( a sales invoice), I was able to duplicate all the data on a record, even on the portal. but when I save the record, all the data in the portal is gone! and whenever I go to another record, the data is gone also.

 

I can see the portal records but its gone the minute I save or go to another record.

 

I think when I duplicate the record, it does not save it to the line item?

 

What could be the cause of this?

 

This is the script i use by Philmodjunk

 

Freeze Window

Set variable [$RecordNumber ; Value: Get ( RecordNumber ) ]

Duplicate Record

Set Variable [$ID ; SALES::pk_ID]

Go To Record/Request/Page [$RecordNumber]

If [ Not IsEmpty ( LineItems::fk_ID ) /* there are line items to duplicate */]

   Go To Related Record [Show only related records; From table: lineItems; Using layout: "lineItems" (lineItems)]
   Go To Record/Request/Page [first]
   Loop
      Duplicate Record
      Set Field [ LineItems::fk_BOMID ; $ID]
      Omit Record
      Go To Record/Request/Page [first]
      Omit Record
      Exit loop If [ get ( FoundCount ) = 0 ]
   End Loop
   Go To Layout [original layout]
  Go To Record/Request/Page [Last]
End IF

 

 

Thank you!

Outcomes