B4J Question [b4j] WaitFor and ResumableSub on Server Handler - devpialkt (first post)    
Oct 25, 2017   
(1 reaction)Woww.. thank you for your quick response...
solved .. with this https://www.b4x.com/android/forum/threads/resumable-subs-wait-for-sleep-in-server-handlers.81833/#content
:)...
link: /android/forum/pages/results/?query=WaitFor+and+ResumableSub+on+Server+Handler...
link: any sample WaitFor and ResumableSub thats support for module "Server Handler"...
B4J Code Snippet Resumable Subs (wait for / sleep) in server handlers - Erel    
Feb 16, 2020   
(15 reactions)Resumable subs can only work when there is a message queue.
By default, server handlers end when the Handle sub is completed. They do not create a message loop.
If you want to wait for an event then you need to call StartMessageLoop and later StopMessageLoop.
Example of handler that downloads a page and returns it as the response:
Sub Handle(req As ServletRequest, resp As ServletResponse...: Use the correct library.
OkHttpUtils2_NonUI for server apps and OkHttpUtils2 for UI apps.
Above tip...
B4A Tutorial [B4X] Resumable subs that return values (ResumableSub) - Erel    
Aug 25, 2020   
(41 reactions)   
tags: wait, Comm, Code, B4X, Dialog ResumableSub, Wait For Button1_Click
Dim rs As ResumableSub = Sum(1, 2)
Wait For(rs) Complete (Result As Int)
Log... wait for the resumable sub to complete then return Null from the resumable sub and set the type in...Remember that that a call to Sleep or Wait For in a resumable sub causes the code flow to return to... wait for the sub to complete and get the desired return value.
Sub Button1_Click
Wait For(Sum(1, 2.... In the calling sub, call the resumable sub with Wait For (<sub here>) Complete (Result...
Share My Creation [B4J] [MySQL] [API] Server (Key + Token) and [B4X] User Login Apps - aeric    
Aug 16, 2024   
(39 reactions) database and tables in MySQL server.
jAPI.zip - Source code for server app (B4J).
B4A.zip - Source code for client app using default template (B4A)
B4X.zip - Source code for client app using B4XPages template (B4A, B4i and B4J)
Live server: https://api.puterise.com:17179
12 Jan 2021: Attached...
Updates:
Latest B4XPages user login client apps (using B4J server):
https://www.b4x.com/android... share my B4J API server written in B4J.
Compare to my previous PHP API, this API server implements...
Share My Creation [Project Template] [Web] Pakai Server v6 - aeric    
Oct 27, 2026   
(14 reactions)Pakai Server
Version 6.99 rev4
Pakai Server is a full-stack B4J project template for building modern web applications and REST APIs. It generates all HTML server-side using B4X code (no client-side rendering), leverages HTMX for dynamic interactions without custom JavaScript, and includes both a Web UI and a REST API with auto-generated OpenAPI 3.0 documentation and Swagger UI.
GitHub: https... updated tutorial: https://github.com/pyhoon/pakai-server-b4j/blob/main/TUTORIAL.md
and libraries...
Share My Creation [Project Template] [Web] API Server v2 - aeric    
Jan 16, 2025   
(31 reactions)://github.com/pyhoon/WebApiController-B4J
Features:
ApiHandler and WebHandler are used for routing...
If you don't want to connect to any SQL database, see MinimaList API Server
For older version... of DbName for SQLite in config.ini
(change) Move code from ConfigureDatabase sub to Initialize sub in DatabaseConfiguration class
(remove) Delete build configurations and code for Firebird, PostgreSQL and MS... tbl_categories
(change) ServerConfiguration Update sub renamed to Finalize
(change) better handling...
Share My Creation [Project Template] [Web] API Server v1 - aeric    
Jan 16, 2025   
(67 reactions), CSS, JS, Bootstrap)
Support MySQL and SQLite database (Can be modified for MS SQL or SQL Express)
Separate SQL queries file (queries-mysql.ini and queries-sqlite.ini)
Sample database auto-generated for... Libraries folder.
Open B4J and create a new project with "Web API Server" template.
Give your... browser.
To connect to MySQL server, go to Objects folder and open "config.ini".
Comment...
- Web API Server - v1.16
- Similar to Web API Template 2.0, it is now less confusing by using #Desc and...
B4A Tutorial [B4X] B4XPages - Cross platform and simple framework for managing multiple pages - Erel    
Dec 25, 2025   
(81 reactions). The class template is very simple and looks like this:
Sub Class_Globals
Private Root As B4XView.... You can see the list of events by writing: Sub + space + tab and choosing B4XPageManager. The event... makes B4A behave more similar to B4J and B4i where the new "B4XPage" element is a regular object that is never paused, never destroyed, can be accessed from anywhere and easy to work... be locked to a single orientation.
3. It is supported by the latest versions of B4J, B4i and...
B4A Library [B4X] FTP Server implemented with Socket and AsyncStreams - Erel    
Jul 18, 2022   
(41 reactions)   
tags: B4A B4J, FTP on the control port (main port).
It also manages the connected clients and assigns a data port for... for each task that requires communication over the data socket (upload, download and list files).
FTPDataConnection - An instance is created for each data task. It sends or receives the data and then...") 'user name and password.
server.BaseDir = File.DirRootExternal
server.Start
SetPorts - Sets... B4i you also need to stop the server when the application moves to the background and start it again...
B4i Tutorial FirebaseNotifications / Push Messages (server not required) - Erel    
May 5, 2026   
(7 reactions)   
tags: Erel)
Msgbox(Message, "Push message!")
CompletionHandler.Complete
End Sub
Private Sub....148715/
Update: It is simpler to use the new and recommended APN authentication keys: https://www.... Create a new explicit (non-wildcard) App ID with the package name of the push app. For example... with a Distribution / Ad Hoc provision profile. This way you can use the same tokens during development and in.... There should be a file named aps_*.cer in the keys folder. Now you should click on Tools - Build Server...
Page: 1  
2  
3  
4  
5  
6  
7