Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Jan-Erik Lärka

Pages: [1] 2 3 ... 23
1
Programming / Re: REXX IDE recommendations?
« on: August 09, 2025, 11:08:18 am »
Hello Dan,

I like the newer eFTE v1.1 and MED.

REXX Tips & Tricks v3.60 contain a lot of useful info.

You may want to look at this post: Topic: REXX tutorials -- start developing applets under ArcaOS out-of-the-box
that contain a script that download and create program objects for rexx.

 1. REXX for the absolute beginner
 2. Rexx Reference Summary Handbook
 3. REXX Tips & Tricks v3.60
 4. Learning REXX Programming in 56,479 Steps
 5. OS/2 REXX. From Bark to Byte
 6. REXX Programmers Reference 2nd Edition
 7. REXX Tutorial
 8. A Practical Approach to Programming
 9. OS/2 2.1 Rexx Handbook (Warning! 321MB)
10. Extending the Workplace Shell with Object Rexx

2
Games / Re: Please test - OpenTTD v12.1
« on: July 18, 2025, 07:18:53 am »
For new user trying it output:
[D:\OpenTTD]openttd
Error: No available language packs (invalid versions?)

the important thing to look for is to check what version you're trying of OpenTTD and download the Windows-32-bit .zip (for OpenTTD 14.1: "openttd-14.1-windows-win32.zip") package that contain all the files needed, unpack them (except openttd.exe) next to openttd.exe by Paul.

Hmmm trying setting the set lang to en_us....

It might fix it :-)

Roderick

Hahaa, If one just download the huge openttd.exe from here and try it, one get that message. One has to also get the Win32 .zip and unpack the files to the same folder and to actually make it work. Language doesn't matter, the message is misleading that way.

I would like to get a screen captures of how to retrieve audio and music in german, english, french, italian, dutch and swedish to complete the wpi I've put together. The problem here is that screen capture doesn't work with sdl2 window, so someone that run it in a virtual machine can get it?!

3
Games / Re: Please test - OpenTTD v12.1
« on: July 16, 2025, 07:19:06 am »
For new user trying it output:
[D:\OpenTTD]openttd
Error: No available language packs (invalid versions?)

the important thing to look for is to check what version you're trying of OpenTTD and download the Windows-32-bit .zip (for OpenTTD 14.1: "openttd-14.1-windows-win32.zip") package that contain all the files needed, unpack them (except openttd.exe) next to openttd.exe by Paul.

4
Games / Re: Please test - OpenTTD v12.1
« on: July 14, 2025, 08:48:00 pm »
Hello David,

how do one run it?
what do one need to use it? (yum /y install SDL2)
any need to manually download the 3 game packages from the site?

5
Applications / Re: Mouse Cursor disapear.
« on: July 02, 2025, 09:13:47 am »
The mouse pointer (image) seen on the screen disappear, but the function still is there.

Move our mouse repeatedly so it en upp in the lower left corner (if xCenter is positioned there), lift the mouse if you have to between movements. The bubble help will appear over the button it hoover.

Click on the X/OS/2-Warp/eCS/ArcaOS-button and use the keyboard to navigate to the Program->Utilities->Text Editor
Once it start successfully as mentioned the mouse pointer image apoear again.

Another way is to try to click on the desktop, press P on the keyboard, Enter, U, Enter, T, Enter... unless there is another folder/program object that start with the letter that you may need to compensate for.

6
sqlite3 seems to use special syntax

Yes, it is somewhat special, but also useful once one find out that the character ; (semicolon) is important.

In the below example one load the database (en2sv.db3) at start by specifying the name as parameter to sqlite3
Then one can input a command that begin with a . (dot) or SQL query.
The enter key just add a new line, while ; & Enter instruct sqlite3 to process what has been entered on the lines above since previous instruction.

Code: [Select]
OS/2 Command Interpreter version 4.5


[D:\PROGRAMS\DRDIALOG\WRD2NLV]sqlite3 en2sv.db3
SQLite version 3.28.0 2019-04-16 19:49:53
Enter ".help" for usage hints.
sqlite> SELECT
   ...>  *
   ...> FROM
   ...>  CLASSIFICATION
   ...> LIMIT 3;
1||Substantiv|152
2||Adjektiv|152
3||Räkneord|152
sqlite>
National characters such as ä above appear as UTF-8 characters and not as ä in codepage 850.

The SELECT could have been entered on one line as well, but this illustrate that it is possible to build complex queries over severeal lines.
Read more on https://sqlite.org/index.html and for the vio/cli command line tool https://sqlite.org/cli.html while the gui tool ported by TeLLie provide a more friendly user experience.

7
ok, this pipe info out of the application into the script (WIN),

how do one send instructions out from the script (WIO) into the application (applications stdin)?

8
There's a text file mentioning how to call functions, but most people new to something as this need help to grasp how and why to knit this function together with that to achieve the desired result.

Example 1: "SysFileTree" was unthinkable to me to use to find or search for files when I begun to try Rexx, the function should have been named SysSearchPath, SysFindFile or something along those lines, not "...Tree", totally bonkers name.

Example 2: Pipe in, pipe out. What "end" of the pipe do one define? I want to output data as text instructions/parameters to one end of the pipe to be sent through the pipe into the application as instructions/parameters just as input by keyboard. It should not block the application that run.

Could you enlighten me how to do such things with RXUTILEX?

How to send commands to sqlite3.exe

:D

9
Programming / [Classic Rexx] How can one pipe data to application?
« on: June 10, 2025, 09:15:44 pm »
I have an urgent need to understand how to redirect instructions to a VIO/CLI application (or several) that take commands via stdin and output data to stdout. Depending on the input it exit or require more input.

I've looked at a code sample for ePDF (Print2PS) but it is designed for the oposite situation, and examples for rxu, C/C++ on OS/2 or whatever appear to be unavailable.

Yes, one can write instructions to a file and run it with something like
Code: [Select]
app.exe < "file.txt"|RXQUEUEbut then one must know the reply in advance or ensure to exit (even though one would like to continue in that session).
I use that approach now, but it is ugly, slow etc.

What I need can be described as redirection of stdin and stdout through the use of a (possibly named) pipe.

10
Games / Re: Please test - OpenTTD v12.1
« on: June 01, 2025, 12:09:24 am »
Yes, there no output visible or hidden as i run it on the command line.
with or without redirecting stderr with 2>&1 and/or to a text file.

Ordinary applications woulld complain about missing .dlls and configuration files etc. but this one doesn't even show usage.

So if I add -h it output text on the console... OpenTTD 12.2 ... Seem as if it find the files downloaded and list those, but trying random parameters doesn't start anything. It just finish right away.

The version v1.4 from 2014 start up without parameters and offer to download stuff (before it freeze).

11
Games / Re: Please test - OpenTTD v12.1
« on: May 31, 2025, 01:17:41 pm »
I'm trying to run OpenTTD (the SDL v1.2 version can still be downloaded) but here it just ... finish without anything apparent on screen almost right away. No errors seen and nothing else that tell me what's going on.

I've placed the three .tar files in a sub folder \baseset relative to openttd.exe

12
Programming / Re: [Classic Rexx] Translation database
« on: May 26, 2025, 10:27:35 pm »
Time is up!
Here's the update that add Numerals.
This now also show the word for to_language for prefix, suffix, language and numerals.
The view PHRASE_VW has been adjusted to allow that.

What files should one take on next?
Hmmm, lip packages while we're at it?

13
Programming / Re: [Classic Rexx] Translation database
« on: May 26, 2025, 12:44:19 pm »
You need two files if you want to add text from .msg and .ini files, one with the source language and another built the same way but with text for the destination language.
The script handle missing translations, but may require a watchful eye afterward.

Please do provide an url (and possibly code) or two, for other translation services than google one could use (as backup) as well.
See the script for one code example as of now.

It would also be very convenient if one could add support for more file formats... perhaps system specific files?!
OS/2 system files often need to be disassembled before one can extract the useful stuff.

Do explore and present command line resource (de)compilers along with other tools and scripts to extract text.

The translation team have the knowledge and it would be most useful if they'd share it and we could include such info into a tool so not everyone need to be a rocket scientist, on top of everything else, but can focus on writing good translations.

14
Programming / [Classic Rexx] Translation database
« on: May 25, 2025, 10:50:24 pm »
I've created a script to assemble words and phrases into a database (sqlite3) that can be viewes with DB Browser for SQLite (A huge Thank you TeLLie! for porting it!).

One just need to type
Code: [Select]
set mode=INITand then
Code: [Select]
T2NLV
It use wget to download a dictionary from wikdict (default english to the language your system run as) so it not aimed at those that use en_US or en_UK or similar.

It then build a database and feed the data to it.

The script can also handle translations by Goran Ivankovic such as .DCT and .INI but also .MSG files.
I've included (though renamed .DCT files provided in Gorans translation tool for reference).

Code: [Select]
set mode=IMPORTand then
Code: [Select]
T2NLV en-sv.DCT(change "sv" for your language if available)

Do not try to feed it the file "Words.txt" unless you're ready to let it spend (a lot of) time fetching translations from google.

I would appreciate your help to improve the script and database!

How about a translation tool to go with it to manage all the translation it should be able to swallow.
For those interested may want to poke on it and look att the table "CLASSIFICATION" as well.

Type
Code: [Select]
Set fromlang=frto set the source language by hand
or
Code: [Select]
Set tolang=nlto set destination language by hand.

Test and create a function on the side in another script that output numerals, so such words in the database can be classified.
That code has to be added, but the db contain them already.
rxNumerals: PROCEDURE EXPOSE this.
IF ARG(1) = 0 THEN
   RETURN 'zero'
IF ARG(1) < 20 THEN
   RETURN WORD( 'one two three four ...

15
Storage / Re: How to discover the newly assigned USB drive letter?
« on: May 15, 2025, 10:04:40 pm »
No need to get fancy here...

SysDriveMap() before calling LVM.
SysDriveMap() after calling LVM.
What changed?

something like:

Code: [Select]
/* Comment */
...
before = SysDriveMap()
'@LVM.EXE /RediscoverPRM'
after = SysDriveMap()
DO i = 1 TO WORDS( after )
  IF 0 = POS( SUBWORD( after, i, 1 ), before )  THEN
    SAY SUBWORD( after, i, 1 ) "must be the drive we're looking for!"
END

Nice!

Pages: [1] 2 3 ... 23