accessing web services via visual basic
Hi - I'm trying to access the incident table via web services but have not been successful. Here is the code:Dim rProxy As New ConsoleApplication1.wp1.ServiceNowDim rGetKeys As New ConsoleApplication1.wp1.getKeysDim rGetKeysResponse As ConsoleApplication1.wp1.getKeysResponserGetKeys.number = "INC11470"rGetKeysResponse = rProxy.getKeys(rGetKeys)Console.WriteLine("testing.")Console.WriteLine(rGetKeysResponse.sys_id)Console.ReadLine()
I keep getting NullReferenceException was unhandled at the rGetKeysResponse.sys_id line. Has anyone else been able to get this to work? I have been able to do the same thing in perl and it was very easy, but perhaps I don't understand the data coming back and I don't know how to access it using VB.
https://www.servicenow.com/community/in-other-news/accessing-web-services-via-visual-basic/ba-p/2288273