JSON Data Source

Stimulsoft Reports.WEB discussion
Post Reply
cbrydon
Posts: 173
Joined: Fri May 30, 2014 4:37 pm

JSON Data Source

Post by cbrydon »

Hi, I am wondering how to create a datasource (or determine what type of data source to use) when using a JSON connection.
I've created a JSON connection with the following string "http://localhost/arcgis/rest/services/C ... /0?f=pjson" and have attached a text file with the json information.

When I try to create a new data source with that connection, I've tried "Data from Dataset/DataTables", but that doesn't seem to work. On the NameInSource dialog, I can see my connection listed, but the OK button is not enabled and I can't actually select the datasource (a screen shot is attached).

I've also tried Data from DataView, but my connection isn't even listed on the NameInSource dialog.

Am I going about this the right way or is there another approach I should be using?

I am currently using Stimulsoft Reports.Web version 2015.3

Hope you can help!
Attachments
JSON_Connection.JPG
JSON_Connection.JPG (40.03 KiB) Viewed 5858 times
jsontest.txt
(2.63 KiB) Downloaded 216 times
cbrydon
Posts: 173
Joined: Fri May 30, 2014 4:37 pm

Re: JSON Data Source

Post by cbrydon »

Here is a URL that you could try. Its similar to something I would be using.

http://sampleserver1.arcgisonline.com/A ... 999&f=json
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: JSON Data Source

Post by Alex K. »

Hello,

Please clarify which designer are you use?
Also, please check the last prerelease build.

Thank you.
cbrydon
Posts: 173
Joined: Fri May 30, 2014 4:37 pm

Re: JSON Data Source

Post by cbrydon »

Thanks for the reply Aleksey, I am using Stimulsoft Reports Web version 2015.3 With Flash Player 25 (splash screen is attached).
I can't try out the latest pre-release build right away - unfortunately I have to wait for someone else to put it in place for me and
that could take a while. If the issue is resolved in the latest pre-release build, I'll try to get others to put the installation on a
higher priority list.
Attachments
StimulsoftSplashScreen.JPG
StimulsoftSplashScreen.JPG (22.68 KiB) Viewed 5850 times
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: JSON Data Source

Post by Alex K. »

Hello,

As a way, you can load data from json url in your code and register it as DataSet with RegData() method.

Thank you.
cbrydon
Posts: 173
Joined: Fri May 30, 2014 4:37 pm

Re: JSON Data Source

Post by cbrydon »

Hi Alex, I'm coming back to this issue asfter a number of months and have a few more questions...

I tried entering the following code into the Begin Render event of a report, but I get an error stating that
"The name 'StiJsonToDataSetConverter' does not exist in the current context" Should I be entering it
somewhere else?

var ds = StiJsonToDataSetConverter.GetDataSetFromFile("http://sampleserver1.arcgisonline.com/A ... 999&f=json");
this.RegData(ds);

The code I used was based on what I found at the following link...https://stimulsoft.zendesk.com/hc/en-us ... at-runtime.

I am currently using Stimulsoft Reports. Web 2017.1.6 from June 3, 2017, ASP.NET, Flex.

As I mentioned above, I am able to create a JSON connection, I'm just trying to figure out how to add a DataSource from that connection.

Thanks in advance for any additional guidance you can provide.

Carl
HighAley
Posts: 8431
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: JSON Data Source

Post by HighAley »

Hello, Carl.

At first, we should say that our Flex components are obsolete now.
We are recommending you to look at HTML5 components.

We have checked your JSON file on our latest build. It's possible to add data sources from it.

You should register data before passing the report to the Viewer.

Thank you.
cbrydon
Posts: 173
Joined: Fri May 30, 2014 4:37 pm

Re: JSON Data Source

Post by cbrydon »

OK - Thank You. I'll see what I can do to use the HTML 5 components.
HighAley
Posts: 8431
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: JSON Data Source

Post by HighAley »

Hello.

We are always glad to help you.
Let us know if you need our help.

Thank you.
Post Reply