We would like to build a community for Small Basic programmers of any age who like to code. Everyone from total beginner to guru is welcome. Click here to register and share your programming journey!


Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 777
» Latest member: Charlesprito
» Forum threads: 205
» Forum posts: 2,181

Full Statistics

Online Users
There are currently 30 online users.
» 0 Member(s) | 27 Guest(s)
Bing, Applebot, Google

Latest Threads
TCP/IP Socket Programming
Forum: Extensions
Last Post: litdev
Yesterday, 12:33 PM
» Replies: 18
» Views: 594
Modbus extension
Forum: Extensions
Last Post: litdev
08-22-2025, 07:58 PM
» Replies: 14
» Views: 178
Challenge 13 - Search uti...
Forum: Challenges
Last Post: AbsoluteBeginner
08-18-2025, 08:14 AM
» Replies: 7
» Views: 160
Small Basic Coder-A New G...
Forum: Discussion
Last Post: z-s
08-18-2025, 06:58 AM
» Replies: 0
» Views: 26
Question about a program
Forum: Standard Small Basic
Last Post: litdev
07-20-2025, 04:18 AM
» Replies: 4
» Views: 475
LDCommPort
Forum: Extensions
Last Post: Eddie
07-14-2025, 01:22 PM
» Replies: 8
» Views: 306
Creation of SB-Neuron. Ou...
Forum: Discussion
Last Post: AbsoluteBeginner
07-09-2025, 07:21 AM
» Replies: 105
» Views: 14,311
I finished making my web-...
Forum: Standard Small Basic
Last Post: sm4llprogrammer2008
07-04-2025, 05:04 PM
» Replies: 0
» Views: 79
Diving into Z-S's SB.js w...
Forum: Standard Small Basic
Last Post: sm4llprogrammer2008
06-26-2025, 05:23 PM
» Replies: 2
» Views: 171
SBJS coming soon
Forum: Standard Small Basic
Last Post: sm4llprogrammer2008
06-25-2025, 01:54 PM
» Replies: 2
» Views: 151

 
  Google Search Terminal SB Edition v2.0
Posted by: sm4llprogrammer2008 - 06-24-2025, 12:11 AM - Forum: Standard Small Basic - Replies (1)

(NOT sVB)
Finally out!
This adds a lotta features!
Requires LD + ZS extensions. (SB 1.2 only)
ID: PXCR310.000
Listing: https://smallbasic.com/program/?PXCR310.000
Code is too long.

Print this item

  Google Search Terminal SB Edition
Posted by: sm4llprogrammer2008 - 06-23-2025, 09:47 PM - Forum: Standard Small Basic - No Replies

And I've been making it today.
It actually launches a search (via LDProcess) and also parses the query, but doesn't URL encode it.
More features might come soon (GST: SBE v2!)
ID: CVJT898.000
Program listing: https://smallbasic.com/program/?CVJT898.000

Code:
Sub PauseNoMsg
  TextWindow.WriteLine("PRESS ANY KEY TO CONTINUE ... ")
  TextWindow.PauseWithoutMessage()
EndSub
Sub SetToDefaultColor
  TextWindow.ForegroundColor = DefaultColor
EndSub
Sub Logo
  TextWindow.ForegroundColor = "Blue"
  TextWindow.Write("G")
  TextWindow.ForegroundColor = "Green"
  TextWindow.Write("O")
  TextWindow.ForegroundColor = "Red"
  TextWindow.Write("O")
  TextWindow.ForegroundColor = "Yellow"
  TextWindow.Write("G")
  TextWindow.ForegroundColor = "Blue"
  TextWindow.Write("L")
  TextWindow.ForegroundColor = "Green"
  TextWindow.Write("E")
  TextWindow.ForegroundColor = "Red"
  TextWindow.Write("!")
  SetToDefaultColor()
EndSub
Sub Search
  TextWindow.WriteLine("")
  TextWindow.Write("What'd you like to search?")
  getsearch = TextWindow.Read()
  parsedsearch = LDText.Replace(getsearch," ","+")
  LDProcess.Start("https://google.com/search?hl=en-us&udm=14&q="+parsedsearch,"")
  Search()
EndSub
TextWindow.Title = "DOSBox (MS-DOS)"
DefaultColor = TextWindow.ForegroundColor
TextWindow.Write("C:\DOS\NET\TOOLS\GOOGLE>")
totype[1] = "g"
totype[2] = "o"
totype[3] = "o"
totype[4] = "g"
totype[5] = "l"
totype[6] = "e"
totype[7] = "."
totype[8] = "c"
totype[9] = "o"
totype[10] = "m"

For i=1 To Array.GetItemCount(totype)
  TextWindow.Write(totype[i])
  Program.Delay(70)
EndFor

TextWindow.WriteLine("")
TextWindow.Title = "Google Terminal 8981"
TextWindow.ForegroundColor = "Yellow"
TextWindow.Write("WARNING: ")
TextWindow.ForegroundColor = DefaultColor
TextWindow.Write("It is recommended to run this simulation with a really fitting typeface style! Right-click the title bar, click 'Properties', go to 'Font' and scroll until you find 'Raster Fonts', then select it, then select 7x12 on the 'Size' section and click 'OK' (works best on Win10/11, might work on 8/8.1 or 7 though)")
TextWindow.WriteLine("")
PauseNoMsg()
TextWindow.WriteLine("")
TextWindow.Write("Google is starting")
For i=1 To 10
  TextWindow.Write(".")
  Program.Delay(100)
EndFor

TextWindow.WriteLine("")
For i=1 To 6
  TextWindow.WriteLine("")
EndFor

Logo()
TextWindow.WriteLine("")
Search()
PauseNoMsg()

It all started when I realized SB's conhost instance's typeface could be tweaked to feel more like DOS.
In Win10/11, first you'd Win+R, then type 'conhost', then right-click the titlebar, then click 'Properties', then go to 'Font', then scroll 3 times (w/ a mouse) until you find "Raster Fonts", then click it, and then select 7x12 from the 'Size' list, then click 'OK'.
I'm playing around with this typeface, it feels like Windows 7 when WT did not exist and console host was king!

Print this item

  LDGraphicsWindow.TransparentGW() only one
Posted by: martmen - 06-11-2025, 11:54 AM - Forum: Extensions - Replies (2)

Hello LitDev,

In the BJTN694.000 program, I am trying to create four windows. Windows 1–3 using LDGraphicsWindow.TransparentGW(), and the fourth window with LDWindows.Create().
However, only the first and last windows are being generated. Can LDGraphicsWindow.TransparentGW() only create one window at a time?
Is there anything you can change about this?

Best regards,
Martin

Print this item

  Replace Small Basic?
Posted by: z-s - 06-09-2025, 02:22 AM - Forum: Discussion - Replies (12)

After all discussion I think i should create SharpBasic basic version of CSharp with small basic syntax and library but much more stuff.
So I set this my current goal but I need help of you people on this forum for every step.
So first should we create it on .Net core (8,9,10) or .net framework 4.8

EDIT BY litdev

Split from https://litdev.uk/mybb/showthread.php?ti...16#pid2316 since this is a big new topic

Print this item

  WV2.sb (Small Basic for WebView2) Beta
Posted by: sm4llprogrammer2008 - 06-07-2025, 02:58 PM - Forum: Standard Small Basic - No Replies

Coming soon, I'll just compile it & test IntelliSense.
Soon GitHub (making account)

Print this item

  working with two windows
Posted by: martmen - 06-07-2025, 08:42 AM - Forum: Extensions - Replies (1)

Hello LitDev,

when working with two windows, the current window must be activated. In the first window, I create controls, such as a text shape. In the second window, I create a ListView. The second window is the active window. Can I simply change the text of the text shape, or do I need to activate the first window first?
The question is: when does a window need to be activated?
I’m looking forward to the answer.

Best regards,
Martin

Print this item

  Error by LDGraphicsWindow.FloodFill
Posted by: martmen - 06-07-2025, 08:31 AM - Forum: Extensions - Replies (1)

Hello LitDev,
In the program MJPH297.000, the command

Code:
LDGraphicsWindow.FloodFill(HGWW, HGWH, "Yellow")
is executed incorrectly. It does not fill the rectangle in the center of the window. Could you please correct this?

Thank you,
Martin

Translated by Capilot

Print this item

  Small Basic super slow ??
Posted by: Elzaimer - 06-04-2025, 08:39 PM - Forum: Standard Small Basic - Replies (24)

Hello everybody,

I found this QBASIC program on Facebook :

DIM SHARED pi, r, t, u, v, x
DIM i AS INTEGER, j AS INTEGER
DIM px AS INTEGER, py AS INTEGER
DIM rr AS INTEGER, gg AS INTEGER, bb AS INTEGER
SCREEN 12
RANDOMIZE TIMER
pi = 4 * ATN(1)
r = 2 * pi / 235
t = 4 * RND
x = 0: u = 0: v = 0
CLS
FOR i = 0 TO 249
FOR j = 0 TO 249
u = SIN(i + v) + SIN(r * i + x)
v = COS(i + v) + COS(r * i + x)
x = u + t
px = INT(320 + 108 * u)
py = INT(240 + 108 * v)
IF px >= 0 AND px < 640 AND py >= 0 AND py < 480 THEN
rr = (i * 3) MOD 256
gg = (j * 3) MOD 256
bb = (255 - (i + j) \ 2) MOD 256
LINE (px, py)-(px + 1, py + 1), _RGB(rr, gg, bb), BF
END IF
NEXT j
NEXT i
SLEEP


I tried it on https://qbjs.org/ and as it was nice I converted it to Small Basic (PSGZ709.000) to compare the performances.
The difference is incredible : 6 seconds on SB and less than a second on QBJS.

Somebone has an explanation ? is my convertion bad ? is there a way to get better performances ? Would Svb be faster ?

Print this item

  SB is actually open-source!
Posted by: sm4llprogrammer2008 - 06-02-2025, 09:07 PM - Forum: Standard Small Basic - Replies (3)

I found the SB dev team's official GitHub profile:
https://github.com/sb

Print this item

  Request for command extension LitDev
Posted by: martmen - 05-27-2025, 06:12 AM - Forum: Extensions - Replies (2)

Hello LitDev,

could you please create a command that generates the contents of the current window as a PDF?
It should also be possible to save it afterward.

Thank you very much for your great extension.

Best regards,
Martin

Print this item