Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ASPJson doesn't work with Windows 2019 IIS #5

Open
pokolokatepetl opened this issue Jan 31, 2021 · 4 comments
Open

ASPJson doesn't work with Windows 2019 IIS #5

pokolokatepetl opened this issue Jan 31, 2021 · 4 comments

Comments

@pokolokatepetl
Copy link

pokolokatepetl commented Jan 31, 2021

Hi there

I was using ASPJson with WIndows 2012 and 2016, but using Windows 2019, it stopped working.

I get error: Description: Object not a collection

When I issue

For Each answer In oJson.data("response")

Any ideas why is this happening?

PS - Problem seems to be related to Msxml2.ServerXMLHTTP.6.0.

@gerritvankuipers
Copy link
Owner

@pokolokatepetl Hi can you provide input Json? And which version of aspjson are you using?

@pokolokatepetl
Copy link
Author

Hi again

Sorry, it was my mistake, ASPJson is working ok, at least the old version. The new version somehow disables our special characters 蚞ȊŽ and they come out as unicode /digits. Could you take a look at the encoding that is different in the new version vs old one from 2014?

@samson007
Copy link

{"id":4936,"external_id":4573,"policynumber":"","amount":7000,"start_date":"2021-03-01","lastname":"SCHUBERT","firstname":"Pietro","street":"Rue de l\u2019industrie 104","postalcode":"7080","city":"La boverid","phonehome":"","phonemobile":"+32 479 16 54 44","company_name":"Nucleus","company_id":5,"date_entered":"2021-02-16T16:52:57.073+01:00","date_modified":"2021-02-17T11:59:01.955+01:00","firstpremiumpayed":false,"sepadomiciliationactive":true}

I get error: Description: Object not a collection

any idea ? version 1.9

@pokolokatepetl
Copy link
Author

pokolokatepetl commented May 4, 2021

The UTF-8 characters do not work in 1.18 version :-( But I have solved it, extended this function:

Private Function aj_JSONDecode(ByVal val)
val = Replace(val, """", """")
val = Replace(val, "\", "")
val = Replace(val, "/", "/")
val = Replace(val, "\b", Chr(8))
val = Replace(val, "\f", Chr(12))
val = Replace(val, "\n", Chr(10))
val = Replace(val, "\r", Chr(13))
val = Replace(val, "\t", Chr(9))
val = Replace(val, "\u017e", "ž")
val = Replace(val, "\u017E", "ž")
val = Replace(val, "\u017d", "Ž")
val = Replace(val, "\u017D", "Ž")
val = Replace(val, "\u010d", "č")
val = Replace(val, "\u010D", "č")
val = Replace(val, "\u010c", "Č")
val = Replace(val, "\u010C", "Č")
val = Replace(val, "\u0160", "Š")
val = Replace(val, "\u0161", "š")
val = Replace(val, "\u0111", "đ")
val = Replace(val, "\u20AC", "€")
val = Replace(val, "\u0107", "ć")
val = Replace(val, "\u0110", "Đ")
val = Replace(val, "\u0106", "đ")
val = Replace(val, "\u00bb", "»")
val = Replace(val, "\u00ab", "«")
val = Replace(val, "\u00a0", " ")
val = Replace(val, "\u20a0", "€")
aj_JSONDecode = Trim(val)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants