|Home » Technical Support » Elevate Web Builder Technical Support » Support Forums » Elevate Web Builder General » View Thread|
|Messages 1 to 6 of 6 total|
|EWB and FMX integration for mobile apps|
|Sun, Jun 13 2021 12:54 PM||Permanent Link|
Hi, I am totally new to web development and my next challenge is to provide web access to parts of a system developed for windows that has been in the market for almost two decades.
In addition to the web interface I am also trying to implement a mobile application using FMX. This is where I would like some input.
What is the best method or tools to convert EWB JSON strings into tables in FMX for local processing and then transform it back to JSON to send to EWB for updates.
Your help will give me the right direction where to look saving a lot of experimentation time.
|Mon, Jun 14 2021 2:37 AM||Permanent Link|
I recently created a thread on the EDB forums for a similar topic of how to get the EDB on mobile, I have started to experiment with the EWB REST with the Delphi REST components with sample code provided by Raul
|Mon, Jun 14 2021 2:14 PM||Permanent Link|
I have managed to establish a connection with EWB using the REST debugger from the Delphi IDE. This is a wonderful tool as you can copy the connection components with the tested properties on a form to complete your project.
Having done that I receive data in a JSON string. My problem is the next step, how to transfer the data in an efficient manner to a table component in order to perform some local operations. Next , of course is to do the reverse operation, how to convert the table data into a JSON string to send to EWB.
I would appreciate any feedback on how to perform this latest step.
|Tue, Jun 15 2021 1:33 PM||Permanent Link|
It appears that I am slowly progressing on the same journey as yourself.
I have got the EWB REST working in the REST Debugger and also now in Delphi thanks to Raul although i'm not sure how the Delph code is handling the EWBSessionID Cookie
I was able to successfully copy the components from the REST Debugger after setting the "JSON Root Element" to Rows. I could also see the Tabular Data in the REST Debugger.
The next steps in Delphi are to enable Live Bindings in the FMX App, and drag the FDMemTable1 * row to the * of a Grid so that the data can be displayed.
I'm still working on your next step "... to do the reverse operation, how to convert the table data into a JSON string to send to EWB."
Let me know if you make any further progress
|Tue, Jun 15 2021 3:12 PM||Permanent Link|
<<I have got the EWB REST working in the REST Debugger and also now in Delphi thanks to Raul although i'm not sure how the Delph code is handling the EWBSessionID Cookie>>
The cookie is passed as a parameter, you can do this in REST debugger by adding it in the Parameters tab, selecting COOKIE in the drop-down box 'Kind'
<<I'm still working on your next step "... to do the reverse operation, how to convert the table data into a JSON string to send to EWB.">>
I came across dataset-serialize
however I haven't tried it with EWB yet
It would be great if Tim could add a client-site adapter component for delphi, that will give a huge boost to the product
|Wed, Jun 16 2021 6:32 AM||Permanent Link|
Tactical Business Corporation
If you search this forum you will find the code I wrote that serializes a dataset to JSON in the format expected by EWB datasets, and from EWB JSON - parses and adds, updates, or deletes records based on the request coming from an EWB dataset commit.