On 13/10/2017 at 10:40, xxxxxxxx wrote:
Hi,
Our plugin has been saving data to the active document for a couple of years now without issue, however we recently had one client contact us where the data would not write/read. This is happening on multiple of their workstations running Win10 and C4D v18.
Here is the code we use to save and retrieve the information.
> import c4d
>
> plugin_ID=1000001 #tmp ID for testing
>
>
>
>
> # WRITE
>
> doc=c4d.documents.GetActiveDocument()
>
> container=c4d.BaseContainer()
>
> myString=container.SetString( 9111, "This is my string" )
>
> doc[plugin_ID] = container
>
>
>
>
> # READ
>
> doc=c4d.documents.GetActiveDocument()
>
> container=doc.GetDataInstance()
>
> newString =container[plugin_ID].GetData( 9111 )
>
> print ' STRING: %s' % newString
This has been working successfully for multiple clients except this one specific client. We also tried changing the read to this:
>
>
>
> # READ
>
> doc=c4d.documents.GetActiveDocument()
>
> container = doc[plugin_ID]
>
> newString = container.GetString( 9111 )
>
> print ' STRING: %s' % newString
This also produced the same result of no data read on their workstations... this does work on ours.
We thought that there may have been a conflicting plugin id but couldn't find evidence of that. Is there another reason that we are missing that would keep data from being saved to a document?
On a side note the same client says that they do not have the issue in C4D v19.
Any help would be greatly appreciated...
Andrew