Looking for ideas !!!
May 24, 2023 07:30PM
Hi,
I need to send a JSON variable/text etc from a Windev Mobile application to a Windev application.
Has anybody done something like this?
I know I can do it with a web service, but I need something that works without a WEBDEV application server.
Are sockets the right way to do it?

Regards
Steven Sitas
Re: Looking for ideas !!!
May 25, 2023 07:36AM
I assume that the data should be received by some kind of web server, but you don't want to use the Webdev application server?

The first thing that comes to my mind is some simple PHP web page that receives the necessary data via a parameter (of course if it is possible to use PHP and a web server...)

If you don't want to use a web server at all, then one of the options is to use sockets, and create an application that listens to a certain port and receives data.
Re: Looking for ideas !!!
May 25, 2023 01:36PM
Hello,

I don't think you can do without a server. Trying to achieve this by using Sockets may prove to be over engineering.

As Marijan suggested use Apache with PHP.

Personally I prefer using php4WDX from my mobile and desktop apps.

Please check this free library.

[mega.nz]

HTH

--
Yogi Yang
Re: Looking for ideas !!!
May 25, 2023 03:09PM
It doesn't need to be WEBDEV server. I send data requests to mysql db by way of php page.

This does the read / write on the db. The WINDEV exe has a timer. it does the reads and udates the screens continuously.

Hope this helps.

Mike
Re: Looking for ideas !!!
May 26, 2023 09:34AM
Hi,
thanks everybody for the suggestions.
I want to make this very simple for the end user - so compatible WX apps can communicate (directly) with NO need for Webservers/Application servers. Nothing else to install except the WX apps (Mobile and Windows).
They could be on the same network or they could just use Bluetooth...

Seems like the only way to do it is with sockets - just like a WX chat application _OR_ maybe MQTT if the broker installation is very simple on an internal pc/server.

Regards
Steven Sitas
Re: Looking for ideas !!!
May 26, 2023 09:44AM
Hello,

The approach I suggested is way better and proven also.

As for setting up PHP just check out Laragon.

It is portable and there is not setup required at all.

[laragon.org]

HTH

--
Yogi Yang
pao
Re: Looking for ideas !!!
May 26, 2023 11:51AM
I don't know WM but if it's possible do connect to a HF/CS DB you can write the JSON in one table and read it in WINDEV.and the other way arround.

It can have some performannce problems but if it's for something simple and for only a few users probably using the BD com do the trick.

Regards

Paulo Oliveira
Re: Looking for ideas !!!
May 26, 2023 01:06PM
Yogi, I will give php4WDX a try and see how it goes.

Paulo, great idea !!!
Since an HFSQL is always installed somewhere on our systems, it looks like a simple and bomb-proof idea.
Now I just may (?) have to implement WX apps that can access 2 different connections at the same time ...

Regards
Steven Sitas



Edited 3 time(s). Last edit at 05/26/2023 02:06PM by SteveSitas.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: