Page 2 of 2 FirstFirst 12
Results 41 to 76 of 76

Thread: RAD Basic vs TwinBasic, Which do you prefer?

  1. #41
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Unfortunately very little progress given it's been a year, with the obvious basis for comparison being how far twinBASIC has progressed in a year and the huge magnitude of such projects.

    Here's the changelog for this and the nov release:

    New
    •New online installer digitally signed. Try to play more friendly with antivirus software.
    •New OpenAI Chat sample.
    •Change location of samples to user profile, avoiding issues with UAC.
    •[Compiler] Add partial implementation of VB.App class.
    •[Compiler] Implemented declaration and use of constants.
    •[Compiler] Add VBA.Constants (vbNewLine, vbCrLf, ...).
    •[Compiler] Implemented "Not" boolean operator.
    •[Compiler] Implemented more functions of VBA.Strings: InStr, Len, Replace, LCase, UCase, Chr and Asc.
    •[Compiler] Initial support of COM api (ActiveX). Implemented CreateObject function which creates and returns a reference to an ActiveX object in runtime (late binding).
    •[IDE] Add comment/uncomment block operations.
    •[IDE] Add Quick Search/Search and Replace operations.

    Improvements
    •Shipped RAD Basic binaries are now digitally signed.

    Fixes
    •[Compiler] On output compiler errors: fixed source code line calculation when there is not Option Module (as 'Option Explicit') and when there are syntax errors.
    •[Compiler] Fix ExpressionSolver with edge cases in calling methods.
    •[Compiler] Fix escape quote char in Strings.
    •[Compiler] Add Click event in forms.
    •[IDE] Fixed clickable compiler errors in output window when path contains parentheses.

    New
    •[Compiler] Rewritten part of the core implementing multi-pass compiler. So, now we will be able to compile source code with methods calling other methods written after them.
    •[Compiler] Support for multiple variable declarations in single Dim statement.
    •[Compiler] Support for visibility modifier (Public, Private, ...) for procedures and variables.
    •[Compiler] Support for additional intrinsic data types: Single, Double and Boolean.
    •[Compiler] Support Boolean operators: 'And' and 'Or'.
    •[Compiler] Added basic string manipulation: concatenation with & symbol, and methods Left, Mid, Right and CInt.
    •[IDE] Add context menu to output window of RAD Basic IDE with "Copy" and "Clear All" actions.
    •[IDE] Add actions to context menu of Project Explorer: Open in File Explorer, Copy Full Path and Open in Terminal.
    •[IDE] New source code editor: with line numbers and code folding.
    •[IDE] Go to line menu item.
    •[IDE] Clickable errors in output window which allows to jump to line.

    Improvements
    •[IDE] Improved dark theme.
    •Added unit testing in IDE (as we had in compiler) and integration tests along e2e tests. These improvements helped to fix a lot of small bugs.

    Fixes
    •[IDE] Fixed various bugs about saving form operation.
    •[IDE] Fixed not losing menu definition on the form when saving.
    •[IDE] Fixed show correctly containers/children in form layout window.
    •[IDE] Fixed bugs in loading/saving VBP, FRM and BAS modules files.
    •[IDE and compiler]: Fixed a lot of small bugs.
    •[Compiler] Check members of an object are callable (not a property) when invoking it.
    •[Compiler] Ignoring case when resolving symbols.
    •[Compiler] Fix read properties.
    •[Compiler] Add a lot of missing checks and fixed small bugs.
    And/Or support was a biggy but it's still pretty useless given parentheses aren't supported... i.e. If (a = 1) Or (a = 2) Then isn't supported.

    At this rate it would likely be 10+ years before RB got to where TB is right now, and given the progress TB has made in the past year, it's likely to pass full compat in less than 1 more year (plus having tons of new features on top, which isn't planned for RB... Carles has said his plan is full compat first, then new language features.). Key takeaway is RB still can't run anything even remotely complicated, while tB already supports a good number of large, complex production apps completely.

    While from a technical standpoint the competition might be good, from a commercial success standpoint I think it's good the market won't be split.

    Finally, it's still worth recognizing that these VB6 replacements are a monumental challenge, and even getting to the point RB is is an impressive achievement that takes a lot of skill, and I expect a lot of the problem here is simply time able to be spent on it.

  2. #42
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,120

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Tweet by @radbasic:

    "AI meets Visual Basic / RAD Basic. This video shows how easy is to create a chat application to query ChatGPT using OpenAI REST API and RAD Basic."

    https://www.youtube.com/watch?v=8TosPmdpZto

    cheers,
    </wqw>

  3. #43
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Seems like something done just to mislead people into thinking it's farther along than it is... you're going to implement late-bound CreateObject calls before you can even handle If (condition1) Or (condition2) Then?

    In fact it looks like it might even be hard coded to specifically support this, and not real support at all. Because I tried an even simpler call,

    Code:
            Dim objShell As Object
    
            Set objShell = CreateObject("Shell.Application")
    
            objShell.BrowseForFolder 0, "Pick a folder", 0, "C:\\"
    And it failed saying it doesn't support the method (except it does, the code works fine in tB and VB6).

    I bet you could not only run that ChatGPT code in tB but do it in it's own thread so as to not lock up the UI.

  4. #44
    PowerPoster yereverluvinuncleber's Avatar
    Join Date
    Feb 2014
    Location
    Norfolk UK (inbred)
    Posts
    2,235

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    No need to assume that Carles is always trying to pull one over your eyes...

    A couple of years ago, if you'd been shown a VB replacement showing that sort of progress you'd have been very impressed indeed. Take it for what it is, a demonstration of some current capability and a taste of what might yet be coming.

    No need to become a fanboy for one solution over another, I am simply very content that we seem to have progress and the possibility of more than one future solution. Competition is capitalism at its best, there are a few capitalists here that should be happy. When you've spoken to Carles personally you'll get the opinion that he is trustworthy, knows his direction, is familiar with the technology and is passionate about delivering it too.
    https://github.com/yereverluvinunclebert

    Skillset: VMS,DOS,Windows Sysadmin from 1985, fault-tolerance, VaxCluster, Alpha,Sparc. DCL,QB,VBDOS- VB6,.NET, PHP,NODE.JS, Graphic Design, Project Manager, CMS, Quad Electronics. classic cars & m'bikes. Artist in water & oils. Historian.

    By the power invested in me, all the threads I start are battle free zones - no arguing about the benefits of VB6 over .NET here please. Happiness must reign.

  5. #45
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    It's not like I'm pulling it out of thin air... even so much as a changelog is locked behind Patreon, virtually no information is public, and now you're going to have CreateObject implemented before some of the most basic syntax, and then I find out that the CreateObject call only works in one specific, narrow demo? Come on... I'm sorry but everything here is pointing to exaggerating progress, and there's only one good reason for that.

    And yeah this may have been impressive 3-4 years ago, but there's never a time where this would be viewed as something likely to be viable in any reasonable timeframe. From a technical standpoint I'm sad about it, it would have been good to have some competition. However at this point, rB isn't on a trajectory where it's likely to ever catch up to tB, and easily a decade off from where tB was a year ago. From a purely pragmatic perspective at this point, there's only one successor, and having a commercial product be sketchy and charging money while making no progress, being very secretive, and doing things like this ChatGPT demo, is IMO *hurting* things because it validates all the hesitation people have about buying into other subscription funded, closed source projects.

  6. #46
    PowerPoster yereverluvinuncleber's Avatar
    Join Date
    Feb 2014
    Location
    Norfolk UK (inbred)
    Posts
    2,235

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Well, I am going to remain optimistic and hopeful. Feels rather nice.
    https://github.com/yereverluvinunclebert

    Skillset: VMS,DOS,Windows Sysadmin from 1985, fault-tolerance, VaxCluster, Alpha,Sparc. DCL,QB,VBDOS- VB6,.NET, PHP,NODE.JS, Graphic Design, Project Manager, CMS, Quad Electronics. classic cars & m'bikes. Artist in water & oils. Historian.

    By the power invested in me, all the threads I start are battle free zones - no arguing about the benefits of VB6 over .NET here please. Happiness must reign.

  7. #47
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    While I'm more inclined to support Fafalone's position, I'll play devil's advocate a bit here. I've said this many times, Wayne is not human. The rate at which he spits out updates is beyond what I think most of even the most talented programmers are capable of. Even if we don't trust Carlos, we know for a fact that Olaf also has the ability to pull something like this off and even his efforts remain more or less in limbo.

    The point I'm making is that perhaps the slow progress of RADBasic is the norm and not the exception. A full VB6 replacement is no easy feat to accomplish by yourself without funding in your spare time. Not to mention the reward is access to a tiny market of a few hundred people at best. TwinBASIC is the exceptional case here and an extreme one in my opinion. Multiple stars had to align for it to happen. So perhaps we should not be too hard on anyone else attempting to create a VB6 clone just because of the high standards set by a single exceptional case.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  8. #48
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    It really doesn't matter whether or not Carles has the ability... the difference IMO we're seeing with that and with Olaf, vs tB, is treating it as a job vs a hobby project. Such a project is a *massive* undertaking, and that's why even people we know have the technical ability like Olaf are getting nowhere fast.

    But Olaf isn't asking for people's money. If you're treating it as a commercial project, and charging money to access some, or in the case of RB, *all*, features, you have a minimal duty to be completely upfront about things like where you're really at and what a realistic timetable is. That's what my issue is here. He's locking up all the information, even things like the changelog, behind a paywall, then the little public information is incredibly sketchy. Like with the ChatGPT sample for reasons I explained... or look at this: https://www.radbasic.dev/components.php That page is *clearly* suggesting all of those *are* reimplemented, rather than "planned to be reimplemented sometime over the next 5-10y". The links to it are titled "List of RAD Basic shipped components" (emphasis mine) and it's even got specific implementation details like "Note: If your project is in Visual Basic 5, you have to upgrade the components of Microsoft Common Dialog Control 5.0 to 6.0 version.". Then you finally get it installed and see you've only got a couple properties for half the default built-in control set.

    So the issue isn't even how long it will take as a side hobby project, the issue is being secretive and misleading in order to get more subscribers, for something you're giving the time commitment of a hobby project while holding it out as a commercial product viable for businesses purposes in a useful timeframe. That's just going to leave a bad taste in people's mouths... there's already enough barriers to asking people to buy into closed source commercial dev software.

    I'd have no problem if Carles was doing like Olaf is doing, or even asking for support *if* it was 100% crystal clear where it is and that it's being done as a side hobby, which means it won't have 'full compatibility' any time this decade. But then you wouldn't get nearly the same subscribers. It would still be great to see another alternative further down the road. However since we now *do* have a real, viable successor, being developed with a commercial time commitment and proceeding on a commercially useful timescale, you don't want people turned off to the whole idea by another project using secretive, sketchy methods to boost subscribers based around not being entirely forthright about status and timeline.


    (PS- I believe you're substantially underestimating the market, as it's a replacement for VBA as well, and Microsoft is once again moving in the VB6 direction... getting ready to leave the millions of users high and dry with a completely incompatible alternative, this time also less powerful because security. You're also proceeding from the assumption it can't gain new users... new languages gain traction all the time, and what else do have that's so beginner accessible? Pretty much just Python, and there's plenty of reasons a modernized VB is better, especially when tB starts support multiple platforms).

  9. #49
    Addicted Member
    Join Date
    Aug 2013
    Posts
    236

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by fafalone View Post
    Microsoft is once again moving in the VB6 direction... getting ready to leave the millions of users high and dry with a completely incompatible alternative, this time also less powerful because security.
    fafalone
    This sounds interesting but I have no clue what you are talking about, if you've time can you explain more about this?

  10. #50
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by vbrad View Post
    fafalone
    This sounds interesting but I have no clue what you are talking about, if you've time can you explain more about this?
    Sure. First, observe the recent trends in macro-enabled document security: First it popped up a warning, then a much more ominous warning, and now if your macro-enabled document comes from the internet, Office will refuse to load the macros *at all*, until you go outside of Office and right click it in Explorer and mark it trusted (or use a tool to manually remove the 'mark of the web' like my ZoneStripper (twinBASIC | VB6). Here's some more details on No Longer Set.

    There's been no significant updates to VBA since 2010, and a lot of new Office features don't work properly with it.

    Microsoft is now pushing Office Scripts. These don't have the full system access or wide ranging capability of VBA, but are Javascript based so have some utility for web and cross platform work. That Microsoft cites the lack of easy web calls in VBA as a reason to use Office Scripts should make someone question why they don't just add new features to VBA for that.

    So it's not hard to see the writing on the wall here: They're making it harder and harder to use VBA through onerous "security" blocks, completely neglecting it on a feature and compatibility level, and have begun introducing an alternative. Can't say exactly when... but the direction it's going is pretty clear.

  11. #51
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    38,988

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by fafalone View Post
    and what else do have that's so beginner accessible? Pretty much just Python, and there's plenty of reasons a modernized VB is better, especially when tB starts support multiple platforms).
    This is an interesting point. I'm not sure how old you are, but I'm kind of thinking that a bunch of us are in roughly the same age group, which is the age group that grew up in the 80s and 90s, with some even older. I believe that you may be coming at this view from the same perspective that I did, and I'm beginning to think that we're wrong about this.

    I'm a biologist, so I tend to work with other biologists, who tend to be fairly well educated (a masters degree at a minimum). When I was in school, there were computers and we all used them to some extent. Those of us who had one of our own were perhaps in the minority, though only slightly, and I might be wrong about that. At the very least, they weren't ubiquitous, they weren't all that cheap, and they weren't all that capable. Those base conditions have changed, and I think beginners might be changing with them. I'm seeing new biologists entering the work force with some programming experience at the college and grad school level. The language of choice, in this field, is R, with python being in second place along with .NET.

    My basic point is: I think there's more education happening at college level than there was in our day. We got into coding by dipping our toes in and finding it quite nice. Those coming up today are often being tossed right in, complete with swim coaches, lifeguards, and so on. They may not NEED introductory languages the way we did. For example, the daughter of a buddy of mine started into C++ as an introduction to programming class, and is loving it. Nobody would consider C++ an introductory language.

    Kids these days may just have so many resources that they don't need to be self taught the way we were.
    My usual boring signature: Nothing

  12. #52
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by fafalone View Post
    It really doesn't matter whether or not Carles has the ability... the difference IMO we're seeing with that and with Olaf, vs tB, is treating it as a job vs a hobby project. Such a project is a *massive* undertaking, and that's why even people we know have the technical ability like Olaf are getting nowhere fast.

    But Olaf isn't asking for people's money. If you're treating it as a commercial project, and charging money to access some, or in the case of RB, *all*, features, you have a minimal duty to be completely upfront about things like where you're really at and what a realistic timetable is. That's what my issue is here. He's locking up all the information, even things like the changelog, behind a paywall, then the little public information is incredibly sketchy. Like with the ChatGPT sample for reasons I explained... or look at this: https://www.radbasic.dev/components.php That page is *clearly* suggesting all of those *are* reimplemented, rather than "planned to be reimplemented sometime over the next 5-10y". The links to it are titled "List of RAD Basic shipped components" (emphasis mine) and it's even got specific implementation details like "Note: If your project is in Visual Basic 5, you have to upgrade the components of Microsoft Common Dialog Control 5.0 to 6.0 version.". Then you finally get it installed and see you've only got a couple properties for half the default built-in control set.

    So the issue isn't even how long it will take as a side hobby project, the issue is being secretive and misleading in order to get more subscribers, for something you're giving the time commitment of a hobby project while holding it out as a commercial product viable for businesses purposes in a useful timeframe. That's just going to leave a bad taste in people's mouths... there's already enough barriers to asking people to buy into closed source commercial dev software.

    I'd have no problem if Carles was doing like Olaf is doing, or even asking for support *if* it was 100% crystal clear where it is and that it's being done as a side hobby, which means it won't have 'full compatibility' any time this decade. But then you wouldn't get nearly the same subscribers. It would still be great to see another alternative further down the road. However since we now *do* have a real, viable successor, being developed with a commercial time commitment and proceeding on a commercially useful timescale, you don't want people turned off to the whole idea by another project using secretive, sketchy methods to boost subscribers based around not being entirely forthright about status and timeline.
    I actually agree with all of this. I'm just willing to give him the benefit of the doubt. He may be trying is very best and just doesn't have the acumen to properly manage expectations and public perception of his product. Of course, he could just be looking to make a quick dollar off the appeal of a VB6 clone. We really don't know but for now, I prefer to imagine the former scenario.

    Realistically speaking though, I think TwinBASIC is the clear winner in this race. It's too far along for anyone else to catch up now.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  13. #53
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by fafalone View Post
    (PS- I believe you're substantially underestimating the market, as it's a replacement for VBA as well, and Microsoft is once again moving in the VB6 direction... getting ready to leave the millions of users high and dry with a completely incompatible alternative, this time also less powerful because security. You're also proceeding from the assumption it can't gain new users... new languages gain traction all the time, and what else do have that's so beginner accessible? Pretty much just Python, and there's plenty of reasons a modernized VB is better, especially when tB starts support multiple platforms).
    I think you might be wrong here. I pretty much agree that MS has a tendency to hang their customers out to dry. They did it when they replaced VB6 with .Net. They did it when they killed Silverlight. They did it when they killed VB.Net to focus on C#.

    Now I used to believe, like many people, that this is a distasteful practice and we might have been justified in our anger when MS does this. However, lately I've been increasingly recognizing the wisdom of what Microsoft is doing. I didn't have the proper perspective to understand why Microsoft is behaving this way. I'm sure that many of you like me have been into BASIC for practically your entire lives. Sure we may dabble in another language here and there, perhaps a bit of C or assembly, some HTML and JavaScript but our core has always been some flavor BASIC running on the Windows platform. This means that we are used to doing things a very specific way and we think this way is the best way, after all it has served us well for decades.

    I've recently gotten a growing interest is just what is going on outside of our tiny little world of Windows development. I've been reading a lot about the kinds of things people are doing these days and the tools they are using. It soon occurred to me that our way of doing things is so damn backwards.

    I mean we are still writing code like this:-
    Code:
        Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
            Dim b As New Button
    
            b.Text = "Click me!"
            b.Width = 150
            b.Height = 30
            b.Left = 10
            b.Top = 30
    
            AddHandler b.Click, AddressOf EH_Click
            Me.Controls.Add(b)
    
        End Sub
    
        Public Sub EH_Click(ByVal sender As Object, ByVal e As EventArgs)
            MessageBox.Show("Clicked.")
        End Sub
    A more modern coding style would look like this:-
    Code:
        Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
            ControlAdder.CreateControl(Of Button).
                WithParent(Me).
                WithSizeAndPos(10, 30, 150, 30).
                WithText("Click Me!").
                WithClickEvent(Sub() MessageBox.Show("Clicked.")).
                Add()
        End Sub
    This is a very basic mock-up of a fluent style API that uses the builder pattern and this is barely scratching the surface of all the various design patterns that are favored by modern programmers. In fact, if that example were real, it would not even be in something like a Form_Load event handler. It would be injected as a service into the Form using an interface or abstract class, perhaps even an anonymous function. This is how modern programmers write code. In this context, I understand now why MS is reluctant to deal with BASIC. It's very difficult to fit it into a world where programmers are used to very un-BASIC-like ways of doing things.

    If TwinBASIC is to attract more than just the VB6 community, it would need to be able to support modern design patterns in a very elegant way. I don't know if you remember but just getting the += operator added to TwinBASIC caused a huge riot. TwinBASIC is going to need to lot more than that to support modern ways of writing code.
    Last edited by Niya; Mar 26th, 2023 at 03:01 PM.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  14. #54
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Just for fun lets look at a more practical example:-
    Code:
        Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    
            Dim dlg As New OpenFileDialog
    
            dlg.Filter = "Text files|*.txt|All files|*.*"
            dlg.Multiselect = False
            dlg.CheckFileExists = False
    
            If dlg.ShowDialog = DialogResult.OK Then
    
                Try
                    TextBox1.Text = IO.File.ReadAllText(dlg.FileName)
                Catch ex As Exception
                    MessageBox.Show("Error opening file : " & ex.Message)
                End Try
    
            End If
    
        End Sub
    The above is typical code for opening a "Open File" dialog. Now there is nothing wrong with that code. It's a perfectly acceptable way of writing code. This is the way us "old-schoolers" would write it. That doesn't mean it couldn't be better. You could make that far more readable while not giving up anything:-
    Code:
        Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    
            FluentOpenDialog.Create().
                AddFilter("Text files", "*.txt").
                AddAllFilesFilter().
                FileAction(Sub(fn) TextBox1.Text = IO.File.ReadAllText(fn)).
                ErrorAction(Sub(ex) MessageBox.Show("Error opening file : " & ex.Message)).
                Open()
    
        End Sub
    The above is the same code written in the fluent style. It does the same thing while being more compact and readable. I find languages that allow you to write code like this very attractive. That doesn't mean I won't use a language without it but it certainly helps in making the language more attractive.

    By the way, for the curious mind, this is what the FluentOpenDialog class looks like:-
    Code:
    Public Class FluentOpenDialog
        Public Shared Function Create() As FluentOpenDialog
            Return New FluentOpenDialog()
        End Function
    
        Private _filters As New List(Of (String, String))
    
        Private _fileAction As Action(Of String)
    
        Private _errorAction As Action(Of Exception)
    
        'Prevent this class from being created
        'by anything other than the Create method
        Private Sub New()
    
        End Sub
    
        Public Function AddFilter(ByVal fltName As String, ByVal filter As String) As FluentOpenDialog
            _filters.Add((fltName, filter))
            Return Me
        End Function
    
        Public Function AddAllFilesFilter() As FluentOpenDialog
            Me.AddFilter("All files", "*.*")
            Return Me
        End Function
    
        Public Function FileAction(ByVal act As Action(Of String)) As FluentOpenDialog
            _fileAction = act
            Return Me
        End Function
    
        Public Function ErrorAction(ByVal act As Action(Of Exception)) As FluentOpenDialog
            _errorAction = act
            Return Me
        End Function
    
        Public Sub Open()
            Dim dlg As New OpenFileDialog
    
            dlg.Multiselect = False
            dlg.CheckFileExists = False
            dlg.Filter = String.Join("|", From v In _filters Select $"{v.Item1}|{v.Item2}")
    
            If dlg.ShowDialog = DialogResult.OK Then
                Try
                    _fileAction.Invoke(dlg.FileName)
                Catch ex As Exception
                    _errorAction.Invoke(ex)
                End Try
            End If
        End Sub
    
    
    End Class
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  15. #55
    Frenzied Member
    Join Date
    Aug 2020
    Posts
    1,421

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    I really enjoyed seeing Niya write some .Net code to compare with VB6, and I could learn a lot from it. Thank you, Niya.

    I've been reading a lot of c# and vb.net code for the past year, and I've been comparing them to VB6 as I read. C# and vb.net have a lot of better features than VB6, but on the other hand, they seem to make a lot of simple things very complicated.

    In VB6, the Form_Load event looks like this:
    Code:
    Sub Form1_Load()
    
    End Sub
    In VB.Net, the Form_Load event looks like this:
    Code:
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
    End Sub
    This is a typical case, "5% increase in functionality and 50% increase in complexity"

    In addition, due to the simple and powerful visualized IDE of VB6, we rarely use or write the following code:
    Code:
     Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
            Dim b As New Button
    
            b.Text = "Click me!"
            b.Width = 150
            b.Height = 30
            b.Left = 10
            b.Top = 30
    
            AddHandler b.Click, AddressOf EH_Click
            Me.Controls.Add(b)
    
        End Sub
    
        Public Sub EH_Click(ByVal sender As Object, ByVal e As EventArgs)
            MessageBox.Show("Clicked.")
        End Sub
    We just need to use:
    Code:
    Sub Button1_Clic()
        MsgBox "Clicked"
    End Sub
    That said, after reading hundreds of thousands of lines of C# and VB.NET code, I actually prefer VB6 and twinBasic. Of course, I continue to learn a lot of valuable things from C# and VB.NET, and I'm more and more amazed at the power of C# and VB.NET

    Note:
    Not to argue, just to learn more. Would love to see Niya write more comparative .NET code, thanks again Niya.

    Edit:
    Although C-style languages now have the upper hand, Basic-style languages will still have a large usage base. We need to work together to make the Basic language more and more user-friendly.
    Last edited by SearchingDataOnly; Mar 26th, 2023 at 10:08 PM.

  16. #56
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by SearchingDataOnly View Post
    In addition, due to the simple and powerful visualized IDE of VB6, we rarely use or write the following code:
    Code:
     Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
            Dim b As New Button
    
            b.Text = "Click me!"
            b.Width = 150
            b.Height = 30
            b.Left = 10
            b.Top = 30
    
            AddHandler b.Click, AddressOf EH_Click
            Me.Controls.Add(b)
    
        End Sub
    
        Public Sub EH_Click(ByVal sender As Object, ByVal e As EventArgs)
            MessageBox.Show("Clicked.")
        End Sub
    We just need to use:
    Code:
    Sub Button1_Clic()
        MsgBox "Clicked"
    End Sub
    We have a designer in .Net as well. I only chose to do it by code to illustrate how we tend to write our logic. It was perhaps not the best example as it's too contrived. We'd almost never write UI code like that in .Net.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  17. #57
    Frenzied Member
    Join Date
    Aug 2020
    Posts
    1,421

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by Niya View Post
    We have a designer in .Net as well. I only chose to do it by code to illustrate how we tend to write our logic. It was perhaps not the best example as it's too contrived. We'd almost never write UI code like that in .Net.
    Understand. I would say that a good IDE can compensate for a lot of the shortcomings of a programming language. Office-Script (TypeScript) is amazing, but it doesn't have a great visual IDE like VB6 or VB.NET.

    In addition, Basic-style programming languages are easier to take advantage of the power of IDEs than C-style programming languages.
    Last edited by SearchingDataOnly; Mar 26th, 2023 at 10:23 PM.

  18. #58
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by SearchingDataOnly View Post
    I've been reading a lot of c# and vb.net code for the past year, and I've been comparing them to VB6 as I read. C# and vb.net have a lot of better features than VB6, but on the other hand, they seem to make a lot of simple things very complicated.

    In VB6, the Form_Load event looks like this:
    Code:
    Sub Form1_Load()
    
    End Sub
    In VB.Net, the Form_Load event looks like this:
    Code:
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
    End Sub
    This is a perfect example of paying a bigger cost up front so you pay a lesser one later. Controls are given a more unified event handling interface like that so that certain tasks become easier. For example, you could now mix and match different types of controls and have a single event handler for any common event among them. For example you could do something like this:-
    Code:
        Private Sub CommonClickEvent(sender As Object, e As EventArgs) _
            Handles PictureBox1.Click, MyBase.Click, ListBox1.Click, Label1.Click, ComboBox1.Click, Button1.Click
    
            Debug.WriteLine("The " & sender.GetType.Name & " control has been clicked!")
        End Sub
    Notice that event handler is handling the click event for different types of Controls. This would be a little more complicated in VB6 as you would have to set up multiple event handlers. You could even set this up dynamically like this at runtime:-
    Code:
        Private Sub Form2_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    
            For Each c In Me.Controls.Cast(Of Control)
                AddHandler c.Click, Sub(s, eh) Debug.WriteLine("The " & s.GetType.Name & " control has been clicked!")
            Next
    
        End Sub
    Now the wiring doesn't have to be hard-coded. The controls will be discovered automatically and wired up at runtime. Any control added to the Form at design time will be automatically discovered and wired up.

    The point is, you buy a lot with this slight increase in complexity.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  19. #59
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by SearchingDataOnly View Post
    Understand. I would say that a good IDE can compensate for a lot of the shortcomings of a programming language. Office-Script (TypeScript) is amazing, but it doesn't have a great visual IDE like VB6 or VB.NET.

    In addition, Basic-style programming languages are easier to take advantage of the power of IDEs than C-style programming languages.
    This also touches on something to connect with the point I was making about earlier about modern coding paradigms.

    One of the things I've noticed is that us in the VB6 and earlier .Net communities are pretty unique in our love for drag and drop designers. But outside of our little bubble, the standard is to have UI logic and backend logic completely separate and only meet through well defined connection points. This is where the modern design patterns I was talking about earlier comes into play. These patterns help in designing very elegant ways of joining separate systems while providing maximum flexibility.

    Drag and drop designers like what we have in VB6 and .Net's WinForms don't really mesh well with this modern way of designing programs. These designers encourage you to mix UI code with other types of program logic so when a client comes along and tells you he wants the program to have a UI on Linux and you have to use a UI framework like say, GTK+, you're in trouble. Now you have to untangle the non-UI bits from the UI bits.

    Now this isn't to say that what we have is bad or wrong. It's well suited for us as a lot of us are more or less confined to Windows-based UI development work but this won't work well for full-stack development where you can have multiple technologies that are fundamentally incompatible with each other working together. For example, you might have Python-based backend that powers an HTML frontend for the Web users and an Android frontend for mobile users. You might also expose an HTTP REST-based API written in something like C# and so on. Drag/Drop designers just don't have much of a role in this environment.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  20. #60
    Fanatic Member 2kaud's Avatar
    Join Date
    May 2014
    Location
    England
    Posts
    996

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Nobody would consider C++ an introductory language
    What would now be considered a suitable intro language? Looking at a dozen UK universities Computer Science course online perspectives, the most popular language seems to be Java, then Python. I only found one that taught c/c++ as a 1 semester 2nd year course. Javascript was also quite popular.

    My first programming language (at secondary school early 1970s) was HP Time Shared Basic (TSB) which was based upon Dartmouth Basic. At University the main language used was Pascal - with Fortran77 and Algol68 also used. Cobol, Snobol and Lisp were also taught (1 semester on each).
    All advice is offered in good faith only. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/

    C++23 Compiler: Microsoft VS2022 (17.6.5)

  21. #61
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    38,988

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by 2kaud View Post
    What would now be considered a suitable intro language? Looking at a dozen UK universities Computer Science course online perspectives, the most popular language seems to be Java, then Python. I only found one that taught c/c++ as a 1 semester 2nd year course. Javascript was also quite popular.

    My first programming language (at secondary school early 1970s) was HP Time Shared Basic (TSB) which was based upon Dartmouth Basic. At University the main language used was Pascal - with Fortran77 and Algol68 also used. Cobol, Snobol and Lisp were also taught (1 semester on each).
    I guess I don't know. I've never taken a course in any language, introductory or otherwise. When I was in HS, there were classes in BASIC and Pascal, though the teacher of the Pascal class didn't know much about it himself. In college...I have no idea what was offered.

    I think people should start out in Rockstar.
    My usual boring signature: Nothing

  22. #62
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    38,988

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by Niya View Post
    This also touches on something to connect with the point I was making about earlier about modern coding paradigms.

    One of the things I've noticed is that us in the VB6 and earlier .Net communities are pretty unique in our love for drag and drop designers. But outside of our little bubble, the standard is to have UI logic and backend logic completely separate and only meet through well defined connection points. This is where the modern design patterns I was talking about earlier comes into play. These patterns help in designing very elegant ways of joining separate systems while providing maximum flexibility.
    I'd take this in a different direction: Drag and drop IDEs are certainly easy to use, but they are also becoming increasingly problematic. Is there a drag and drop IDE for the web? Can there be? Web pages, if well written, have to be able to reasonably transform themselves to fit appropriately on a phone, a tablet (of various sizes), and a desktop. The best interface on each might be quite different. For example, what is a menu of pictures with text on a desktop could shrink to a menu of just text on a tablet, and to a drop down menu (or pop out, or fan fold, or something else) on a phone. Doing that via drag and drop seems like it would be impossible.

    The closest IDE design that I can think of, which attempts to allow drag and drop for variable sized displays, would be XAML for Xamarin or WPF, and anybody who has used either of those knows that the drag and drop is such a trivial part of the IDE that it is forgettable. Now that I'm writing in WPF, I find that I write everything in the XAML and just don't use the drag and drop portion. The visual part of the IDE is there to see what I have, but all design is done in the XAML designer, which is just text (XML-like text, at that) for those who haven't seen it.


    Basically, the drag and drop IDE of VB6, .NET, and just a few others, is really well suited for building desktop programs that will run on computers with a relatively narrow range of resolutions. They are best for interfaces that don't have to shift dynamically as the screen size changes radically, because they are for programs that aren't intended to run on radically different screen sizes and resolutions.
    My usual boring signature: Nothing

  23. #63
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    The primary difference between classic VB6 drag/drop paradigm and modern UI paradigms implemented in things like XAML and HTML is that the latter is all about relative positioning and sizing. Everything is sized and positioned in relation to something else. Drag and drop designers cannot work with this requirement as it relies on absolute values for size and position. This is why the drag and drop features of the WPF designer goes unused. It screws up the UI because it applies absolute values to elements which fundamentally disagrees with WPF's layout engine. It can only be done in code. It's the same problem for HTML.

    Quote Originally Posted by Shaggy Hiker View Post
    Basically, the drag and drop IDE of VB6, .NET, and just a few others, is really well suited for building desktop programs that will run on computers with a relatively narrow range of resolutions.
    I agree but even so, I still think flow-based layout engines are better even in this environment. I see so many layout based questions in the VB.Net section that make me think, "this would be so easy in WPF". Yet, I can't suggest it because of WPF's intimidating learning curve but once you get past that, it's well worth it.

    All in all I still think there is a compelling argument for the older WinForms/VB6 drag and drop designer, it's just so damn easy to learn. It only becomes difficult when you try to do anything fancy.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  24. #64
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    38,988

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    That reminds me of the old quote: For every problem, there's a solution that is simple, obvious, and wrong.

    I wouldn't say that a drag and drop IDE is wrong, it just doesn't do well in all types of problems.
    My usual boring signature: Nothing

  25. #65
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    The drag and drop designers in VBx *do* rely on absolute positioning, but there's no reason they *have to*.

    For instance tB already has 'anchor' properties that can resize elements along with the form, relative to their margins in the designer (like most of us implement manually anyway).

    You could easily allowing accepting % for measurements... i.e. Width = 50%. Could make a live previewer that shows it on different sizes...

    I just don't see any scenario where it's easier to write UIs with no visual clues whatsoever. Good designers are frequently a source of complaints about what people think their language is missing.

  26. #66
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,598

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    WPF has a visual designer with full drag and drop capability just like WinForms and VB6 but it's very ineffective because fundamentally WPF's layout engine is flow based like HTML. Elements are relatively positioned by default so when you start dragging and dropping controls, they just snaps into a random place, often where you don't want them to be because it cannot use the absolute co-ordinates from your drag and drop action. This makes for a very poor experience so we don't use that feature. We just write the UI code by hand, which by the way is far less painful than it sounds. In fact, I've grown to prefer this way of writing UIs. I no longer have to spend tedious seconds dragging and stretching controls on a Form in an effort to try and line them up perfectly. I just describe the layout in relative terms and get exactly what I want.

    However, as you implied, an absolute positioning layout engine can be shoehorned into producing flow-based UIs. They are more flexible at the cost of some additional complexity. For example if you want to a make a flow-based UI in WinForms or VB6, you have basically do it by performing the layout calculations yourself. Properties like anchoring do help to make some of it easier but it can get really complex if you want anything too fancy.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  27. #67
    PowerPoster
    Join Date
    Jan 2020
    Posts
    3,746

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by Niya View Post
    I'm really curious about it since there was so much fuss over it. However, I am terrified of ransomware. There are very few things in the world that frighten me more than the prospect of waking up one morning to find all the files on my HD encrypted so I avoid running EXEs from people or companies I know nothing about. That fear is far greater than my curiosity.
    auto backup ,you need it.

    two disk save same files

  28. #68

  29. #69
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Looks like download is available if you just increment the version from last time.

  30. #70
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,120

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by fafalone View Post
    Looks like download is available if you just increment the version from last time.
    👍

    cheers,
    </wqw>

  31. #71
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Looks like we missed a release this month...


    RAD Basic 0.5.93 Pre-Beta 4 - Release Notes

    RAD Basic Pre-Beta 4 release (0.5.93.0)

    Pre-release of Beta 4 Notes: This is an early access to Beta version.
    New
    • [IDE] Added Show Logs and Collect Logs operations under Help Menu for troubleshooting problems.
    • [IDE] Added formatting check in numeric values of Option Dialog and Project Properties Dialog.
    • [IDE] Added configuration of editor's font and font-size.
    • [IDE] Support to add/edit/save/remove BAS modules.
    • [IDE] Support to add/edit/save/remove Class modules.
    • [Compiler] Add support to #If…Then…#Else Directive (conditional compilation).
    • [Compiler] Add support to #Const Directive (define conditional compiler constants).
    • [Compiler] Defined RADBASIC, Win32 and Win64 const directives.
    • [Compiler] Add initial support for IO (Open, Close, Line Input statements).
    • [Compiler] Initial support of Class modules compilation.

    Improvements
    • [IDE] Remember last folder visited for saving new items.
    • [IDE] Added more internal log to help troubleshooting issues.
    • [Compiler] Improve managing of unexpected errors in runtime/usercode.

    Fixes
    • [IDE] Fix Clickable error in output window for syntax errors.
    • [IDE] Fix bug in String syntax highlighting.
    • [Compiler] Fix compiling process of projects with items (Forms, Modules, …) in different directories.
    • [Compiler] Fix compilation of procedures without explicit visibility (public/private).

    Known issues
    • [IDE] Form Designer Grid: not drawn properly while user resizes form and some performance issues in certain edge cases.
    • [IDE] FRX values (Icon, Pictures, ComboBox List, …) are readonly values in Form Designer, as there issues saving into FRX file.
    • [Compiler] UDT only support basic types as members.
    • [Compiler] Variant type is not supported.
    • [Compiler] Option Explicit is mandatory. Source code without option explicit will be supported in followings releases.


    Uh oh Wayne better watch out, at this rate it might be only 5 years instead of 10 before radbasic is at where tB is now

  32. #72
    PowerPoster
    Join Date
    Jan 2020
    Posts
    3,746

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Happy new year

  33. #73
    PowerPoster
    Join Date
    Jul 2010
    Location
    NYC
    Posts
    5,647

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    And another one, this time with.... well, nothing.

    RAD Basic 0.6.0 Pre-Beta 6 - Release Notes

    RAD Basic Pre-Beta 6 release (0.6.0)

    Pre-release of Beta 6 Notes: This is an early access to Beta version.
    New
    • [Platform] New AutoUpdate module, easing stay updated. It is an experimental feature.
    • [IDE] New Samples Explorer.
    • [IDE] New Factorial sample featuring recursion.
    • [Compiler] Add recursion support in functions.
    • [Compiler] Check Option Explicit is on when compiles. Raise error if Option Explicit is Off, as it is not supported by compiler.

    Improvements
    • [IDE] Add missing icons in Form Layout.

    Fixes
    • [Compiler] Fix error in declaration of Sub/Function without explicit visibility (Private/Public keyword).

    Known issues
    • Installer and executables are not digitally signed because we are managing renovation of code signing certificate.
    • [IDE] Form Designer Grid: not drawn properly while user resizes form and some performance issues in certain edge cases.
    • [IDE] FRX values (Icon, Pictures, ComboBox List, …) are readonly values in Form Designer, as there issues saving into FRX file.
    • [Compiler] UDT only support basic types as members.
    • [Compiler] Variant type is not supported.
    • [Compiler] Option Explicit is mandatory. Source code without option explicit will be supported in later releases.


    Apparently monthly releases are to be their new norm.

    tB hasn't had a release in 1.5 months now, but that's an massive aberration, usually there's dailies with more new features than this. My bet is back up to 8y for RB.

  34. #74
    Addicted Member
    Join Date
    Mar 2009
    Posts
    244

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by Niya View Post
    Just for fun lets look at a more practical example:-
    Code:
        Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    
            Dim dlg As New OpenFileDialog
    
            dlg.Filter = "Text files|*.txt|All files|*.*"
            dlg.Multiselect = False
            dlg.CheckFileExists = False
    
            If dlg.ShowDialog = DialogResult.OK Then
    
                Try
                    TextBox1.Text = IO.File.ReadAllText(dlg.FileName)
                Catch ex As Exception
                    MessageBox.Show("Error opening file : " & ex.Message)
                End Try
    
            End If
    
        End Sub
    The above is typical code for opening a "Open File" dialog. Now there is nothing wrong with that code. It's a perfectly acceptable way of writing code. This is the way us "old-schoolers" would write it. That doesn't mean it couldn't be better. You could make that far more readable while not giving up anything:-
    Code:
        Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    
            FluentOpenDialog.Create().
                AddFilter("Text files", "*.txt").
                AddAllFilesFilter().
                FileAction(Sub(fn) TextBox1.Text = IO.File.ReadAllText(fn)).
                ErrorAction(Sub(ex) MessageBox.Show("Error opening file : " & ex.Message)).
                Open()
    
        End Sub
    The above is the same code written in the fluent style. It does the same thing while being more compact and readable. I find languages that allow you to write code like this very attractive. That doesn't mean I won't use a language without it but it certainly helps in making the language more attractive.
    I guess it's all in the eye of the beholder, as with the 'old style' I think that's much more readable as the fluent version. Compact doesn't always mean more readable.

  35. #75
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,120

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    Quote Originally Posted by SuperDre View Post
    I guess it's all in the eye of the beholder, as with the 'old style' I think that's much more readable as the fluent version. Compact doesn't always mean more readable.
    So you decided to reply to this one year old random message out of pure desire to clarify things to these young heads?



    cheers,
    </wqw>

  36. #76
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    38,988

    Re: RAD Basic vs TwinBasic, Which do you prefer?

    That does seem in keeping with the spirit of the thread, though. Posts are far between, yet the thread has never been totally moribund...unlike the question, which seems increasingly settled.
    My usual boring signature: Nothing

Page 2 of 2 FirstFirst 12

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width