David,
You need to define the objects as shared objects. You will also want to use
collections instead of arrays because I don't think you can have a shared
array.
This works without error :
*C_COLLECTION*($DeleteRecord_ob)
$DeleteRecord_ob:=*New shared collection*
*C_OBJECT*($DeleteRecord_PN_ob)
$DeleteRecord_PN_ob:=*New shared object*
*C_OBJECT*($Delete_ob;$Delete_PN_ob)
$Delete_ob:=*New shared object*
$Delete_PN_ob:=*New shared object*
*Use* (*Storage*)
*Storage*.t:=*New shared object*("DeleteRecord";$Delete_ob
;"DeleteRecord_PN";$Delete_PN_ob)
*End use*
*Use* (*Storage*.t)
*Storage*.t.DeleteRecord:=$DeleteRecord_ob // this line generated the
error message
*Storage*.t.DeleteRecord_PN:=$DeleteRecord _PN_ob // so does this line
error with same message
*End use*
On Sat, Sep 1, 2018 at 8:35 PM David Ringsmuth via 4D_Tech <
[email protected]> wrote:
> I’m trying to add an object array to Storage.
>
> The documentation says that Objects can be a share storage value.
>
> I keep getting the message “Not supported value type in a shared object or
> shared collection.”
>
> In the below code I broke apart the assignments for easiest debugging.
>
> ARRAY TEXT($DeleteRecord;Get last table number)
> ARRAY LONGINT($DeleteRecord_PN;Get last table number)
>
> C_OBJECT($DeleteRecord_ob)
> OB SET ARRAY($DeleteRecord_ob;"DeleteRecord";$DeleteRecord)
>
> C_OBJECT($DeleteRecord_PN_ob)
> OB SET ARRAY($DeleteRecord_PN_ob;"DeleteRecord_PN";$DeleteRecord_PN)
>
> C_OBJECT($Delete_ob;$Delete_PN_ob)
>
> Use (Storage)
> Storage.t:=New shared
> object("DeleteRecord";$Delete_ob;"DeleteRecord_PN";$Delete_PN_ob)
> End use
> Use (Storage.t)
> Storage.t.DeleteRecord:=$DeleteRecord_ob // this line generated
> the error message
> Storage.t.DeleteRecord_PN:=$DeleteRecord _PN_ob// so does this
> line error with same message
> End use
>
> Please help!
>
> David Ringsmuth
>
> **********************************************************************
> 4D Internet Users Group (4D iNUG)
> Archive: http://lists.4d.com/archives.html
> Options: https://lists.4d.com/mailman/options/4d_tech
> Unsub: mailto:[email protected]
> **********************************************************************
--
Kirk Brooks
San Francisco, CA
=======================
*We go vote - they go home*
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive: http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub: mailto:[email protected]
**********************************************************************