Quantcast
Channel: West Wind Message Board Messages
Viewing all articles
Browse latest Browse all 10393

Re: DeserializeJson Call

$
0
0
Re: DeserializeJson Call
West Wind Internet Protocols
Re: DeserializeJson Call
Feb. 5, 2013
12:38 pm
3PJ0R3KPIShow this entire thread in new window
Gratar Image based on email address
From:Roger Bradshaw
To:Rick Strahl
The error is "Unable to load wwDotNetBridge: Unable to load Clr Instance".

In the current path, I have wwipstuff (ver 5.65.0.0), wwdotnetbridge (ver 5.66.0.0).

I've scoured my local drive for older versions of these DLLs and do not see any that could possibly be in play now.


What's the error?


If the Init() fails, then again it's most likely the missing wwipstuff.dll or wwdotnetbridge.dll in your FoxPro path. Both DLLs are best if they are in the current path.

+++ Rick ---



The code below still fails in DserializeJson

DO wwJsonSerializer && Load libs
DO wwDotnetBridge

loJson = CREATEOBJECT("wwJsonSerializer")
lcJson = '["Value,1","Value2. This \"is\" neat","Value3"]'
loResult =loJson.DeserializeJson(lcJson)


The failuer happens within "Init" in wwdotnetbridge with this IF statement.

*** Fail creation if the object couldn't be created
IF ISNULL(this.Load())
ERROR "Unable to load wwDotNetBridge: " + this.cErrorMsg
RETURN .F.
ENDIF


No. wwDotnetBridge does not get loaded by default.

But doing:

DO wwJsonSerializerDO wwDotnetBridge

somewhere to load the libraries is required.

+++ Rick ---



I see DeserializeJson() in the latest wwJsonSerializer.prg, but not in wwDotnetBridge.prg (dated Feb 3 in the zip file I downloaded yesterday).

After recompiling everything I could think of, I'm getting a different error - file GetwwDotnetBridge.prg does not exist. I see this is in wwDotNetBridge.prg. Shouldn't these routines be available by my starting up with "DO WWCLIENT"?

Make sure you recompile all of your files. Look in the help file for updating to the latest version or updating from the shareware version.

DeserializeJson() should be there ( you can double check the wwDotnetBridge.prg source file)...

+++ Rick ---



Yes, I am a registered user and downloaded all of the latest upates yesterday. I'm looking at the Help and trying to determine what needs to be loaded in advance of me calling DeserializeJson. I have the latest WCONNECT.H (file date Feb 3) in my base development folder and "DO wwclient" runs at when I start up in development.


... and only the very latest version that was released a couple of days ago. The shareware version has not been updated yet - it's only in the registered version at this point.

+++ Rick ---



I have the very latest wwIpstuff.dll, wwDotnetBridge.dll and NewtonSoft.Json.dll in the same folder as where I'm doing my development. However, the code below returns the error "Property DESERIALIZEJSON is not found". Can you let me know what I could be missing?

DO wwJsonSerializer && Load libs

loJson = CREATEOBJECT("wwJsonSerializer")

lcJson = '["Value,1","Value2. This \"is\" neat","Value3"]'
loResult =loJson.DeserializeJson(lcJson)














Viewing all articles
Browse latest Browse all 10393

Trending Articles