Site icon Embarcadero RAD Studio, Delphi, & C++Builder Blogs

Display JSON Base64 images created in C++Builder using Ext JS in browser

Author: h.mohri

Output to JSON Base64 Image Data Reading Browser.
I use Ext JS. And the JSON server is C++Builder bcc32.

 

Create a standalone new project for WebBroker.

 

 

Add action on TWebModule side.

PathInfo is set to "/img".

 

It is a code to output JSON corresponding to CORS.

Code that can be compiled with bcc32. For CORS please refer to the following URL.
https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS

[crayon-68bf35d9e3f24668292086/]

The output JSON is as follows.

[crayon-68bf35d9e3f2d518009427/]

Ext JS design.

Create image and button screens using Sencha Architect.

Add Store.

[crayon-68bf35d9e3f2f783937568/]

Create a button event for Ext JS.

[crayon-68bf35d9e3f31863703404/]
Exit mobile version