Export Picture Fields as WebService in NAV 2009 SP1

Dear All,

I am trying to publish a picture field as web service in NAV 2009 SP1. Since I am not very familiar with automation objects I couldn’t manage to succeed so far. I tried to replicate functions codeunit 99008516 - BizTalk XML DOM Management but I realized that I can not even compile the object because automation variable Base64 cannot be loaded.

What should I do to use Base64 object, how and which library should I load to it work?

Thanks and Regards,


Hi Ararat,

When you work with automation’s then it’s my experience that one of the things that often goes wrong is the versions. In your case that “could” be the problem. Normally when you install NAV or the prerequisites, then you should be able to compile all objects without additional installs. Are you able to compile codeunit 99008516?

If yes, how did you create the automation variables in your new code? If you created them manually, then this may where you could have choose the wrong version of the automation. If you copied them, then they would most likely be ok.

Hi Erik,

Unfortunately, codeunit 99008516 is not compiling. It cannot load the selected library and the Subtype of Base64 variable seems like ‘Unknown Automation Server.Unknown Class’.

Is there another way to expose a blob field in a web service other than using automation objects?

That SHOULD work. If it doesn’t work, then 99% sure it’s your installation, as it installs the automation, when you install NAV.

Or you could try to install the XML automation again. You find it in the prerequisite folder of the DVD.

We found another installation folder, reinstalled it again and now the objects are compiling. Thank you for your help.