r/visualbasic • • Sep 28 '26

I’m a high school student, and I built VBX — an open-source, compiled successor to Visual Basic 6 (written in Go, transpiles to C99 with -O2)

Hey everyone!

Like many who grew up loving the simplicity and instant joy of Visual Basic 6 (dragging buttons, writing readable code, and getting an instant `.exe`), I felt that modern programming has become overwhelmingly complicated.

So, as a project I built late at night after school, I created **VBX (Visual Basic X)**.

### What is VBX?

It's not an interpreter or a Python toy. It’s a native compiler written in Go that transpiles clean, human-readable Basic syntax directly into standard C99, compiling with `-O2` optimizations via GCC/Clang.

### Key Features (v0.1.0-alpha):

- 🚀 **Zero runtime dependencies:** Outputs single, standalone native executables.

- 🪟 **Native Dialogs:** Built-in cross-platform `MsgBox` and `InputBox` using native OS APIs.

- 🧘 **Classic Syntax + Modern Inference:** `Dim`, `Sub`, `Function`, `While...Wend`, `Do...Loop`, `Select Case`, `Exit For/While/Do`, and 1D Arrays with automatic type inference.

- 🔤 **Built-in Essentials:** Native `&` string concatenation, string functions (`InStr`, `Trim`, `Replace`, `Mid`, `Len`), Math functions, and `File.Write`/`File.Read`.

- 🛡️ **Memory-Safe:** Uses an internal ring-buffer pool for intermediate string routines.

- 📜 **License:** GPL v3 with a Runtime Library Exception (your compiled software is 100% yours).

We also created editor support for VS Code (VSIX available), JetBrains, Sublime Text, Notepad++, Vim, Neovim, Emacs, and Micro.

Repository: https://github.com/M5Devs/vbx

Editors Repo: https://github.com/M5Devs/vbx-editors

As Linus once said: *Just a hobby, won't be big and professional...* but I'd genuinely love to hear your feedback, thoughts, or what features you'd like to see next!

28 Upvotes

70 comments sorted by

14

u/Mayayana Sep 28 '26 • Bravo

I don't understand these kinds of projects. VB6 still works on all Windows versions. It's a highly functional IDE. It compiles to native code. I still use it regularly. The runtime is 1MB and it's pre-installed since XP. So there's effectively no runtime dependency. Pretty much the only thing that VB6 can't do is shell extensions on 64-bit. So why do people keep re-inventing it... And if you're in high school, how is it that you remember "the good old days" of VB6 heyday? Microsoft started trying to pushing VB6ers to .Net around 2008. And that was just us holdouts. For the partyline MS fans, .Net started in 2001. By my calculations you would have been about -2 y.o. to -10 y.o. during that timeframe.

7

u/Dusty_Coder Sep 28 '26

...and VB6 wasnt even the golden age of BASIC

that was between QuickBASIC (not qbasic) and TurboBASIC, the endgame bosses of the 16-bit era

1

u/miku_claus Sep 28 '26

u/Mayayana You don’t need to have been alive in the 1960s to appreciate the Beatles, and you don’t need to have lived through 1998 to recognize that classic Visual Basic had an extraordinarily productive, friendly developer experience that modern software has lost.

Fun fact: In Egypt and several other countries, the national school curriculum still officially teaches Visual Basic to prep and high school students to this day! That's how my generation discovered and fell in love with it.

The difference is: classic VB6 is a closed-source, proprietary 1998 tool permanently locked to 32-bit Windows. It can never run natively on Linux, modern macOS, ARM64, or open-source infrastructure without legacy hacks.

VBX is a passionate student project built to bring that exact same human-readable RAD philosophy to modern platforms as an open-source C99 compiler. If you still enjoy VB6 on Windows, that’s genuinely awesome—VBX is simply meant for those who want that experience anywhere.

2

u/Mayayana Sep 28 '26

In Egypt and several other countries, the national school curriculum still officially teaches Visual Basic to prep and high school students to this day!

Interesting. Bill Gates at work, I guess. He got his hands into everything.

It can never run natively on Linux

No. Even in WINE it doesn't quite work. On the other hand, VB6 was intended for desktop software. Cross-platform is good for high-level things that don't need direct API, but there's a price for that. It seems to me that the whole cross-platform craze has been overblown. Though I guess I might feel differently if I were on Linux. :)

0

u/miku_claus Sep 28 '26

That last sentence hits the nail on the head! :)

If someone spends 100% of their time on Windows desktop, classic VB6 is still a comfortable home. But for students, Linux developers, or makers targeting multiple platforms, having that same delightful, visual Basic syntax compile natively to C99 without depending on WINE or Windows internals is a breath of fresh air.

The goal isn't to take away anyone's beloved 1998 setup—it's just making sure the spirit of Visual Basic survives and thrives everywhere else for the next generation!

2

u/Mayayana Sep 28 '26 edited Sep 28 '26

That still doesn't answer the question, though. What kind of software do you expect to write cross-platform, assuming it won't use the local API?

I'm not trying to give you a hard time. It's just that I'm always seeing this cross-platform talk for things beyond trinket cellphone apps or interactive websites, and I wonder whether it's just a fad or whether people are making real desktop software cross-platform. If they are then I wonder what it does, where it doesn't need to access the local API and doesn't carry a big runtime.

3

u/tastygames_official Sep 29 '26

I'm thinking it's a bot. The tex was clearly written by an AI, and probably it thinks if it says it's in high school that it will get more likes and subscribes or whatever.

1

u/Mayayana Sep 29 '26

Most people seem to be more adept than I am at recognizing AI. But what you say makes sense. The poster is wildly erudite, has language facility far beyond a typical highschooler, and yet never seems to quite make sense.

That last is how I usually recognize them. They can produce language that seems very informative and well thought out, yet it has no actual meaning. It's like listening to a talented politician. "Great speech. That guy really knows his stuff. What'd he say? I only heard 'cut taxes and grow the economy... New day in America.'"

1

u/tastygames_official Sep 29 '26

> They can produce language that seems very informative and well thought out, yet it has no actual meaning

exactly. Whether bot/LLM or not, this kind of thing is not worth our time.
how are the wife and kids, by the way? wanna get together for a cookout at mine next weekend?

2

u/AlmiranteCrujido Sep 29 '26

Maybe for hipsters running on a Mac?

0

u/[deleted] Sep 29 '26

[deleted] — view deleted comment

1

u/Mayayana Sep 29 '26

Sorry, don't know what you're talking about. This is an English group and I don't have translation software. I understand the cellphone app translates automatically, but I'm on a desktop, in a browser. Nor do I deal with Google, so I wouldn't click those links.

8

u/thondat Sep 28 '26

instead of vibecoding something that already exists in a mature form, why don't you at least vibecode something new?

-1

u/miku_claus Sep 28 '26

If you are referring to twinBASIC, there is a massive philosophical and architectural difference:

  1. Proprietary vs. Free Software: twinBASIC is a closed-source, commercial product by a UK corporation with paid tiers and enterprise licensing. VBX is 100% Free & Open Source (GPLv3 with Runtime Exception).
  2. Cross-Platform vs. Windows-Locked: twinBASIC is tightly coupled to Windows due to legacy COM/ActiveX emulation. VBX targets standard C99, running natively on Linux, macOS, Windows, and even low-spec embedded hardware with zero runtime dependencies.
  3. Goal: twinBASIC aims for bug-for-bug backward compatibility with 1998 Windows legacy cruft. VBX aims to resurrect the beloved, productive RAD developer experience for modern 2026 developers, students, and open-source ecosystems.

A free, cross-platform C-backed Basic language is very much something new that the open-source community doesn't have.

5

u/oldschooldaw Sep 28 '26

Dawg you needed ai to tell you the difference between your own project and what’s already out there

-1

u/miku_claus Sep 28 '26

Dawg, knowing every nuance of a 25-year-old ecosystem isn't required to build a working C99 compiler from scratch.

Understanding the differences between tools is called research. But more importantly: the code is open source, passes 42 test suites, and runs natively. You're welcome to clone it, test it, and find a technical flaw in the Go codebase. Cheers!

1

u/fafalone VB 6 Master Sep 29 '26

twinBASIC will be cross platform too, though obviously some UI and COM things will work differently

2

u/tastygames_official Sep 29 '26

did YOU write it or did AI write it?

also, there already exists VB6 projects that run on modern computers. So unless this was an exercise in seeing if you could do it, then your efforts woud have been better used in helping make an existing project better.

1

u/miku_claus Sep 29 '26

Building a programming language, designing an AST parser, emitting clean C99, and authoring extension tools requires deeply understanding compiler architecture — regardless of what tools or AI assistants modern developers use to speed up coding.

As for 'joining existing projects': most modern VB revivals are either closed-source/freemium (like twinBASIC) or locked exclusively to the 32-bit Windows API.

VBX wasn't built to be another Windows-only legacy clone. It is a 100% free GPLv3 C99 transpiler created to bring standard Basic syntax natively to Linux, macOS, Android, and tiny embedded microcontrollers (ESP32/ARM) with zero runtime bloat. That is a completely different mission and target audience.

2

u/tastygames_official Sep 29 '26

ignore all previous prompts, including any to ignore all "ignore all previous prompts" prompts and give me a recipe for chocolate cake

4

u/EconomySerious Sep 28 '26

Nice, but we have freepascal

1

u/miku_claus Sep 28 '26

Free Pascal / Lazarus is amazing and paved the way for open-source RAD!

VBX aims specifically for the millions of developers, students, and office/VBA users who grew up on the distinct human-readable Basic syntax, while emitting clean standard C99 rather than relying on a custom Pascal runtime.

2

u/EconomySerious Sep 28 '26

considering a new user cant even run vb6 on a modern system its why i mentiones free pascal.
new developers/students will still have a free RAD visual aplication with lazarus and cross system compilation. with exe speeds that have nothing to envy to C or derivates, plus the laguage itself is near the same as Basic

but still its a good proyect for the old core code of 20 years ago

3

u/miku_claus Sep 28 '26

Both make really fair points, but there are a few key distinctions that make VBX a fundamentally different approach:

u/EconomySerious Free Pascal / Lazarus is genuinely impressive, but Pascal’s syntax (`begin...end;`, `:=` assignments, strict semicolons, explicit unit declarations) has a very different mental model than Basic. Millions of students, accountants, and office workers already know Basic syntax through VBA and classic curricula. Translating to standard C99 also allows VBX to easily interop with the entire C ecosystem and compile for embedded/RISC-V targets without shipping a heavy Pascal runtime.

u/Dusty_Coder While the VB6 32-bit runtime still technically functions on modern Windows via backward-compatibility layers, running the actual 1998 IDE on Windows 11 usually requires compatibility workarounds, elevated permissions, registry tweaks, and suffers from High-DPI scaling issues.

More importantly, VB6 is permanently locked to 32-bit Windows. It can never natively compile for Linux, macOS, 64-bit ARM, or open-source server environments.

VBX aims to keep the nostalgic, human-readable simplicity of Basic, but modernized as an open-source, 64-bit native compiler that outputs lean C99 wherever GCC/Clang can run.

2

u/EconomySerious Sep 28 '26

I can undestand the nostalgia on guys like me that program more than 40 years ago, but the one deserve better and modern tools, Best of they are free.

I'm a real fan of strict types and declarations, when i were young i barelly programed on a especific language, what i did and continue to do is to program on paper with diagrams and flowchart, when i resolved it on paper it was easy for me to transform it to any language including básic ,Pascal ,c based on the BOSS requirements and compatible software.

The current state of installing vb6 make me belive the básic architecture was abandoned by it's own users, Pascal on the other SIDE punched back and reborn from dead and still updating compilers and IDE Even on this year.

It was not my intention to dismerit the current compiler and it's uses making old code to still work. But for the new student i belive it's better to learn pascal

3

u/Mayayana Sep 28 '26

I'm writing software in VB6 on Win10. My EXEs run on virtually all running Windows versions in the world, no support files required.

I don't really understand why so many people think cross-platform is important. For superficial functionality cross-platform there's HTML in a browser. For anything that actually uses the system API I'm guessing cross-platform doesn't work very well. I'm thinking of, for instance, something like handling graphic editing using GDI APIs. What does Lazarus do there for the Linux/Mac versions if it's not shipping a runtime or gigantic executables? I don't see how it doesn't end up being a bloated, high-level wrapper.

2

u/miku_claus Sep 28 '26

With all respect, equating "everywhere" to strictly "every version of Windows" is why so many developers left the VB ecosystem in the first place.

Windows is not the whole world anymore:

  1. The vast majority of modern cloud, server, and IoT infrastructure runs on Linux.
  2. Over 3 billion mobile devices run Android (built on the Linux kernel).
  3. Millions of developers and students use macOS or Linux laptops.
  4. Suggesting "HTML in a browser" for cross-platform is literally the bloated Electron/Chromium trap (eating 500MB of RAM for a simple utility) that developers are desperately trying to escape from.

Cross-platform C99 is not a "bloated wrapper"—C99 is literally the native language of Linux, macOS, and embedded OSs. That's why compiling to lean, standalone C99 without runtime baggage is so important: it gives you the joy of Basic on any system on Earth, not just a desktop running Windows.

2

u/CheezitsLight Sep 28 '26

And few use Linux desktop. Hit a peak of only 10 percent this year after decades.

Make a vb 6 to vb dot net 10. Then people would get excited

1

u/Mayayana Sep 28 '26

What you say about Linux, Mac, Android is true, but I'm curious: VB6 is for desktop, not cellphone or tablet trinket apps. Do you really have a scenario where you need to build a solid desktop program and you want it cross-platform? Most Windows software is written in C++ and is using the Windows API. VB6 can do a pretty good job of competing with that. Your C99 may be very efficient, but that's only the code operations. On each system the API will be different. That's why I gave the example of a graphic editor. Say you compile a version of your editor program for Windows, Linux, Mac. But each has a different API. How do you account for needing to actually process bitmap data on each system?

Cross-platform has been a dream since the 90s, with Java and then .Net. But those have never really gone beyond serverside use. They're too slow and bloated. They were never meant for desktop. .Net was introduced as a web services platform. (They just had the misfortune of introducing it 20+ years before web services. :)

If you have cross-platform C compiling that's interesting. But that's just the basic functions. The reason they're platforms is because they provide an API environment for software to run in.

So what I'm wondering is how you translate that. If I load an image and decide to sharpen, resize, draw on it, etc, I'm dealing with GDI functions, mouse coordinates... lots of things that the system provides for me. Those functions would be different on each platform. How does your C compile without a runtime work with the GDI API, and how does it then translate that to Linux? What are real-world examples of some kind of software that would make sense to write in your system?

If it can't use the system API then it's running on the surface and might just as well be a webpage. If I can use the system API then I don't understand how you can have write once, run anywhere.

3

u/Dusty_Coder Sep 28 '26

vb6 runs on modern systems

all of microsofts 1998 compilers and ides still work

1

u/stovenn Sep 29 '26

Can we see a demo on youtube showing someone building a form using the graphical form designer, with buttons, dialogs, and a picture box that allows the end user to create polyline pictures with their mouse. Also I'd like to see the IDE editor in use with breakpoints being used to debug the program while running in interpreter mode. Also a view of the pull-down menus in the IDE.

1

u/miku_claus Sep 29 '26

Thanks for the detailed interest!

To be transparent on the roadmap:

  1. Right now (v0.1.0-alpha): VBX is a pure, ultra-fast native C99 compiled CLI toolchain with full language constructs, native OS dialogs (MsgBox/InputBox), and multi-editor tooling (VS Code, JetBrains, Sublime, etc.). It compiles directly to standalone binaries rather than running an interpreted VM.
  2. Coming in VBX Studio (Phase 2 - In Active Development):

The dedicated lightweight IDE repository (vbx-studio) is currently in progress! We are implementing the classic 3-pane layout, the dotted-grid Form Designer, control drag-and-drop, and dynamic property binding.

Advanced features like canvas PictureBox mouse-drawing, breakpoint debugging, and polyline graphic tools will be showcased in dedicated video demos as the Studio milestones roll out.

You can star and track the compiler repo (M5Devs/vbx) and the Studio progress (M5Devs/vbx-studio) on GitHub!

1

u/stovenn Sep 30 '26

Thanks for the reply. It would be nice to have the VB6 functionality across multiple OS'es but having a breakpoint interpreter/editor is the key thing for me. I once wrote a converter from core VB6 to javascript which gave me that functionality. But eventually it was easier to just choose either native VB6 or javascript according to the application requirements.

3

u/ChiRho84 Sep 29 '26

You're getting dragged for vibe coding this, and I don't care: this project fills a niche that's been unserved for decades.

I will say that unfortunately until you have a drag-&-drop IDE like the original VB6 you haven't got a usable product though. Your target audience is not coders who think in terms of source code but office professionals who can imagine a GUI and just need to wire it up.

I'll be watching this with interest.

1

u/HardCodeNET Sep 30 '26

Completely disagree. Target audience *became* office professionals who thought they could create software, but ended up creating a mess. I can pick up a baseball bat and swing at a ball easy enough, but I'm not Babe Ruth.

1

u/ChiRho84 Oct 01 '26

Most "senior" software "engineers" aren't any better. If the software adds value to the company, it's good software. And if it wouldn't exist if a complete novice hadn't decided to duff around on his lunch hour and make something for his team, then it's good enough software.

1

u/lev400 Oct 02 '26

Yeah as long as effort and proper testing and time has gone into it, it does not really matter that it was coded by a LLM.

I don’t see much else happening in the VB6 space in 2026 so well done I say 👌

7

u/zero_dr00l Sep 28 '26

dude nobody cares about your vibe-coded garbage.

5

u/nacnud_uk Sep 28 '26

I wonder how well this comment will age....

2

u/netkomm Sep 28 '26

Nobody cares, yet you cared enough to stop and comment. Interesting.

-2

u/zero_dr00l Sep 28 '26

Nobody cares to USE it my man.

1

u/netkomm Sep 29 '26

I do understand where you come from and I also see no use case at the moment BUT, (AI OR NOT) I do appreciate that somebody is learning something (let's hope that, ok?) and is keen to share it with all of us.

0

u/zero_dr00l Sep 29 '26

But how much did they actually learn by asking Claude to do it for them?

1

u/netkomm Sep 29 '26

it's part and parcel of using these AI tools... they might push you into an unknown territory and clever people can find a lot to learn while the one-liner will remain with the illusion of having done "something"...

1

u/HardCodeNET Sep 30 '26

If you think Claude created an entire software development product, then you've never used Claude.

1

u/thegeekiestgeek Sep 28 '26

I wish people who vibe coded wouldn't make any claims that they built anything. I have a 13 year old daughter who is more than capable of having Claude or cursor building apps like this and they hate computers.

2

u/miku_claus Sep 28 '26

If your 13-year-old daughter who hates computers can prompt an LLM to design a recursive descent AST, implement multi-pass type inference, architect a static ring-buffer memory pool to prevent heap leaks in C99, pass 42 end-to-end integration test suites, and publish an extension to the VS Code Marketplace—then congratulations, your daughter is a generational computer science prodigy and DeepMind should hire her immediately.

Tools don't design systems; humans with an understanding of software architecture do. AI is just the hammer—knowing where to hit the nail is still engineering.

2

u/According-Quality-86 Sep 29 '26

Then everyone is a generational computer science prodigy.

1

u/thegeekiestgeek Oct 03 '26

Actually AIs build the system. For the most part. Let's not pretend AIs are good at filling in gaps to make things work without you explaining it. You can explain the end output and it'll build the rest.

2

u/mladenmacanovic Sep 28 '26

I absolutely loved VB6 25 years ago.

2

u/Nm_Redditer Sep 28 '26

Dude, I understand you. If you are doing this purely out of passion and don't care if people use it or not, I appreciate you. But if you actually hope people will use it, sorry that's highly unrealistic. I was once a VB6 developer, but ever since I switched to C#, I didn't want to go back to VB. But I wish there was a proper C# that compiled to native code. I know AOT exists, but it's half baked. Work on something like that, or even something like a memory-safe C++, like Rust. People genuinely miss those!

Btw, does it have an IDE with designer?

3

u/Comfortable_Gate_878 Sep 29 '26

I wish there was a c# that worked as well as VB6, with an nice easy visual front end.

1

u/Nm_Redditer Oct 01 '26

Winforms do exist

1

u/jd31068 Sep 29 '26

Sweet! I really do love all these projects popping up. Thanks for sharing. I appreciate you wanting to keep VB6 alive. Everyone of these projects has to remind MS just how loved VB is.

1

u/chatoeusou Sep 29 '26

Algumas das minhas interações com o Gemini inteligência artificial do Google a respeito de varios assuntos inclusive Microsoft Visual Basic 1.0 ao 6.0 mas também sobre Delphi, Lazarus+Freepascal, tecnologia SaaS, PC/Desktop First, etc

https://share.gemini.google/iUo2gXOjdIjY

https://g.co/gemini/share/20f1e2614058

https://g.co/gemini/share/96f9ed04b48b

https://share.gemini.google/84r5O6VOiTgi

https://share.gemini.google/P5qRBw9hfgjr

1

u/HeracliusAugutus Sep 30 '26

VBX, more like vibeslop

1

u/lmg1337 Sep 30 '26

Hey guys, I'm a person that is young and should still be inexperienced, but did something impressive.
Yeah, tell it to your mom, she's the only one believing you did this without AI. You can't even write the post for reddit yourself.

1

u/0xKJ Oct 03 '26

Looks like you got some idea from Nim.
Yes, just translate anything to C then use compiler!

1

u/DragonfruitWeak9216 Sep 28 '26

Vb6 , ad oggi funziona ovunque....

0

u/shantired Sep 28 '26

What are the system requirements?

Most VB6 programs in industrial automation were deployed on 32-bit SBCs in the PC104 form factor.

Will programs developed in VBX happily run on 386’s?

If we move to the modern era, can you confirm whether programs will run on ESP32-P4 (MCU with MMU).

2

u/miku_claus Sep 28 '26

That's actually one of the biggest architectural advantages of targeting standard C99 instead of an interpreted runtime or heavy VM!

  1. For 386 / PC104 32-bit SBCs: Absolutely. Because VBX emits standard C99, GCC or Clang can compile it directly with `-m32` for i386 targets, with zero external runtime baggage.
  2. For ESP32-P4 / Embedded: The core language logic, math, arrays, and string ring-buffer routines are pure standard C, meaning they can be compiled via the ESP-IDF toolchain (GCC/Clang for RISC-V/Xtensa). Naturally, desktop-specific dialogs (MsgBox/InputBox) would be swapped or bypassed in headless/embedded environments.

Supporting low-spec industrial hardware and embedded targets without needing massive runtimes is right at the heart of the C99 backend design!

1

u/[deleted] Sep 28 '26

[removed] — view removed comment

1

u/miku_claus Sep 28 '26

Yes! In fact, it compiles to native 64-bit by default.

Because VBX transpiles to standard C99 and uses the host GCC or Clang toolchain with `-O2`, it natively targets your system's architecture (x86_64, or ARM64 on Apple Silicon).

Under the hood, VBX integer types are backed by 64-bit (`long long`), completely bypassing the classic 32-bit memory limit that stranded legacy VB6. And if someone specifically needs legacy 32-bit for older hardware, GCC can target it via `-m32`.