Search found 109 matches

by guest
Wed Jul 08, 2020 4:04 pm
Forum: Liberty BASIC Language
Topic: Sent Bytes to COM Port
Replies: 3
Views: 7

Re: Sent Bytes to COM Port

steinche wrote:
Wed Jul 08, 2020 7:35 am
Does anyone have a tip for me?
It should be:

Code: Select all

Print #ComPort, CHR$(&HA0)+CHR$(&H01)+CHR$(&H02)+CHR$(&HA3);
or

Code: Select all

Print #ComPort, CHR$(160)+CHR$(1)+CHR$(2)+CHR$(163);

The &H prefix won't make any difference in the case of 01 and 02, but is essential for the A0 and A3.
by guest
Fri Jun 19, 2020 1:33 am
Forum: General Board
Topic: How to Enumerate Installed Fonts?
Replies: 3
Views: 152

Re: How to Enumerate Installed Fonts?

Have you considered using the standard Windows Choose Font dialog? If there is some way you could use that, it would be simpler than creating your own font selector using a LB listbox:

Image
by guest
Tue Jun 16, 2020 10:31 am
Forum: General Board
Topic: How to Enumerate Installed Fonts?
Replies: 3
Views: 152

Re: How to Enumerate Installed Fonts?

I would like to have a listbox filled with the Windows installed fonts. Any code greatly apreciated. A Google search found this but it's quite old (1999) and works by exporting the font list from the registry, so I don't know how compatible with 'modern' Windows it is likely to be. It also needs tw...
by guest
Mon Jun 15, 2020 9:17 pm
Forum: General Board
Topic: Liberty Basic 5
Replies: 3
Views: 107

Re: Liberty Basic 5

LB5 looks as if it has promise, but it has still some way to go and the GUI output is still very basic. LB5 sets itself a tough challenge: to support cross-platform GUI features that have a high degree of compatibility with the Windows native GUI controls used by LB4 (and LBB). It may be instructiv...
by guest
Mon Jun 15, 2020 5:45 pm
Forum: General Board
Topic: Liberty Basic 5
Replies: 3
Views: 107

Re: Liberty Basic 5

I notice that Carl Gundel is developing Liberty Basic 5. Is there any interest from Richard in making LBB compatible? It's not possible, not least because LB5 is cross-platform and LBB is Windows-only. Anyway, why would I want to: most of the shortcomings in LB 4 that LBB was written to overcome ha...
by guest
Mon Jun 01, 2020 9:27 pm
Forum: Liberty BASIC Language
Topic: AFTERLAST$ doesn't work when concatenated
Replies: 2
Views: 173

Re: AFTERLAST$ doesn't work when concatenated

Am I missing something obvious or do I need to break this up to use LBB? The most obvious fault is that you are using AFTERLAST$ rather than afterlast$ . The LBB documentation states, in the Liberty BASIC 4.5.0 section: " Note that the function names must be specified in lower-case ". This is inevi...
by guest
Fri May 29, 2020 12:55 pm
Forum: Liberty BASIC Language
Topic: URL to Internet
Replies: 13
Views: 484

Re: URL to Internet

Both programs work regardless if the message is prefixed with http:// or ftp://. That's probably because the file is available via HTTP anyway. My understanding is that URLDownloadToFile will successfully download a file using FTP (so long as the URL starts ftp:// and there is no requirement for a ...
by guest
Thu May 28, 2020 1:09 pm
Forum: Liberty BASIC Language
Topic: URL to Internet
Replies: 13
Views: 484

Re: URL to Internet

URL$="http://tgftp.nws.noaa.gov/data/observations/metar/stations/KPHL.TXT" That should be ftp:// rather than http:// surely? If it's also available via the HTTP protocol you should be able to use httpget$() which is a built-in function in Liberty BASIC 4.5 and is available in LBB via the lb45func.b...
by guest
Wed May 27, 2020 4:45 pm
Forum: Liberty BASIC Language
Topic: URL to Internet
Replies: 13
Views: 484

Re: URL to Internet

JackKelly wrote:
Wed May 27, 2020 3:40 pm
How can this be done in LBB?
(edited)

URLDownloadToFile seems to work fine for the file you specified. I've only tested it in BBC BASIC but it should certainly work in LB/LBB as well:

https://www.rosettacode.org/wiki/Web_sc ... erty_BASIC
by guest
Mon May 25, 2020 10:17 pm
Forum: Liberty BASIC Language
Topic: URL to Internet
Replies: 13
Views: 484

Re: URL to Internet

As I recall, it sent a message to one of your websites and printed the reply, HTML code, to the mainwin. The nearest thing I can find to that description is this by Brent Thorn: ' Minimal TCP/HTTP client ' By Brent D. Thorn, 10/2010 ' A minimalistic TCP client which just happens to send the right s...