What Java library or dll can be used to develop a WEB GUI in Xbase++?

Xbase++ 2.0 Build 554 or later
Message
Author
Diego Euri Almanzar
Posts: 174
Joined: Thu Nov 05, 2020 10:51 am
Location: DOMINICAN REPUBLIC

Re: What Java library or dll can be used to develop a WEB GUI in Xbase++?

#61 Post by Diego Euri Almanzar »

Hello everyone!

I have been using XBASE++ CXP for more than a year, and my application or WEB system works very well. CXP is definitely the best way to develop on the WEB. As a Web server I have used Windows IIS, as well as the option Standalone with HttpEndpoint.

With Windows IIS, it is unstable, sometimes it runs normally, but it gives a lot of errors. Especially when the application tries to use the helpers. That is, the dlls that contain the functions that I use as the interface.

The only advantage with Windows IIS, is that I have been able to upload PDF documents, and display them with iframe tags, or JS libraries for PDF handling.

The modality that has worked very well for me is Standalone with HttpEndpoint. But, I need to upload PDF documents, and via Standaone I can't do it. Obviously, I know it's happening because I don't have cloud hosting. I'm still working on a local computer.
However, I think that if I can upload PDF documents through IIS, I should also upload PDF documents through my HTTPENDPOINT server.

I think that perhaps what my httpendpoint server is missing is the use of certificates, so that the browser accepts any type of document.
The only example I found about digital certificates in combination with httpendpoint is the following:


In addition to plain text connections, HTTP end points also support servicing requests via the Secure Socket Layer (SSL) protocol. For this, an SSL certificate must first be installed on the computer. Once the end point is bound to this certificate, HTTP and web socket connections to this end point can be established via SSL for increased security.
The following code fragment demonstrates the general procedure:
#define PORT 443

// Create an end point for handling incoming
// connections on the default port for HTTPS
// Note: Port and address must be adjusted
// for your environment!
oHttpEndpoint := HttpEndpoint():new( PORT, "localhost" )

// Set the SSL certificate for the local computer.
// The certificate will be used for subsequent
// SSL connections.
// Note: The certificate must be adjusted
// for your environment!
oHttpEndpoint:setCertificate( "machine\my\mycomputer" )

// Start the end point
oHttpEndpoint:start()


The result is that it doesn't work for me. Using the setcertificate statement, just like this in the example, gives me an error. When I use it in the following way, it gives me fewer problems:
oHttpEndpoint:setCertificate(,"my","JCSERVER\APPWEB\ allsetcertificate" )

Still, it doesn't work properly.

I hope you can help me find a way to assign certificates to my website, through oHttpEndpoint:setCertificate, or any other Xbase++ tool for CXP.

I will appreciate it a lot.

Best regards.

User avatar
rdonnay
Site Admin
Posts: 4804
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: What Java library or dll can be used to develop a WEB GUI in Xbase++?

#62 Post by rdonnay »

Are you able to upload PDF files from your Standalone if you make a http:// connection instead of a https:// connection?
The eXpress train is coming - and it has more cars.

Diego Euri Almanzar
Posts: 174
Joined: Thu Nov 05, 2020 10:51 am
Location: DOMINICAN REPUBLIC

Re: What Java library or dll can be used to develop a WEB GUI in Xbase++?

#63 Post by Diego Euri Almanzar »

Hello Roger.

For me it is a great honor, and I feel very privileged that you try to help me, because I know that you are a very capable person, and very intelligent. Beforehand thank you very much.

Also, I want to take the opportunity to thank all those who participate in this forum, since through you I met Bootstrap. This elegant front-end UI framework is impressive. Above all, its mobile first capacity, or layout that adapts to the screen of the device used by the user. The application that I am developing is composed of 90% bootstrap, 10% Vue.js, on the front-end.

I've been working on localhost all this time, because Alaska Xbase++ only gives examples on localhost, and because I'm unaware of Internet communications.

There are two things that I have not been able to achieve:

1. Upload a PDF in an iframe, or through the pdf.js library
2. Move my app out of localhost

Looking for alternatives for the issue of PDF documents, I have started using Windows IIS as a server. And, definitely, the matter was successful. The PDF displays normally with any tool, as long as IIS is used as the server.

My excitement with Windows IIS was short-lived. Because, although it is true that the PDF uploads, in any mode, it is also true that all kinds of errors appeared.

For example, when using IIS as a server, the CXP compiler does not find the Express library (dcclip1.lib), and its includes (#include “dcdialog.ch”).

Noticing all the errors that appear when using IIS as a server, I went back to using Standalone, as a server, where I only have one problem: The issue of uploading PDF documents.

Noticing that through Windows IIS there are no problems with PDFs, I thought I could improve Standalone by adding certificates to it.

I have not been able to add certificates to the Standalone. The statement that Xbase++ has for that matter, is not clear, and also they do not offer examples.

I have tried Standalone with both HTTP port 81 and HTTPS port 443, but in all cases, I have not been able to upload a PDF document.

Maybe if I bought space in the cloud, and installed everything in that space, the certificates would already be available for my website, and I wouldn't have any problem.

But, I don't see the need to continue investing resources until I get better results.

What I did do was buy a domain name. And since I have a domain name, I'm about to hire a telematician, to help me set up my computer as an application server through duckdns, and opening ports on the modem. If I'm wrong about something, please correct me.

In a general sense, these are the only two points I still need to overcome:
1. Get my application out of locahost, and 2. upload PDF from the Httpendpoint or Standalone.

If you can help me, I will appreciate it.

Best regard.

Post Reply