WebPicture URL property being set to Nil on app loading

I’m currently having an issue with changing the Picture property for WebImageViewers over multiple sessions from a WebPicture that is stored inside of a dictionary.

I’m currently receiving a NilObjectException error when attempting to set the image of each WebImageViewer and I believe this is being caused by the WebPicture’s URL property inside of the dictionary. Once the method that is storing the WebPicture in the dictionary finishes, the URL property on the WebPicture goes to an empty string.

This wasn’t an issue on 2019 r3.1 but has been on 2021 r3 and r3.1.
Looking for a solution to this?

Where do you set the URL ?

I’m not explicitly setting the URL for the WebPicture.
Just parsing the picture to the dictionary with the auto-generated URL which is something like “\files\123456\ImageName.png”.

I had also tried setting the session to Nil before parsing the picture to the dictionary but made no difference.

If it needs to work across sessions, make sure you set the WebPicture.Session property to Nil, otherwise it won’t be accessible to all sessions.