Page 5 of 18 FirstFirst ... 234567815 ... LastLast
Results 161 to 200 of 701

Thread: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

  1. #161
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    You are too impatient.
    It was a joke. But also, why bother posting before you have the content for your post? There is a preview for formatting and stuff, but maybe I'm thinking too much into this.. it is Chit Chat afterall and you don't need to make sense!

  2. #162
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    It was a joke. But also, why bother posting before you have the content for your post? There is a preview for formatting and stuff, but maybe I'm thinking too much into this.. it is Chit Chat afterall and you don't need to make sense!
    Because baka's post separated my first post from my second post.

  3. #163
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    Because baka's post separated my first post from my second post.
    I'm gonna come up with an even crazier idea... posting all the content in 1 post!

    Don't mind me today.. I am really trying to avoid work.

  4. #164
    Frenzied Member PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Newport, UK
    Posts
    1,482

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    The simpler code is as follows:

    Code:
    Private Sub Form_Load()
        Dim i As Long, nColor As Long
        
        With mySpread
            .ColHeadersShow = False: .RowHeadersShow = False: .GridColor = vbWhite: .ScrollBars = ScrollBarsNone: .OperationMode = OperationModeSingle
            .MaxRows = 4: .MaxCols = 3: .RowHeight(-1) = 480: .ColWidth(1) = 480: .ColWidth(2) = 2400: .ColWidth(3) = 1200: .FontName = "Verdana"
            
            For i = 1 To 4
                .Row = i:       nColor = Choose(i, vbRed, vbBlue, vbGreen, vbCyan)
                .Col = 1:       .BackColor = nColor:
                .Col = 2:       .ForeColor = nColor:        .Text = "How it looks as text"
                .Col = 3:       .CellType = CellTypeButton:     .TypeButtonText = "Remove"
            Next i
            
        End With
            
    End Sub
    Edit:
    Originally, I didn't want to participate in such a discussion, but some people really need to know more about other knowledge.

    In addition, the features that mySpread can achieve are 100 times more powerful than ComboBox.ItemTemplate.
    That is because they are entirely different things, I am guessing mySpread is a spreadsheet component and a ComboBox.ItemTemplate is a way of changing the appearance of a combobox.

    Plus the WPF example is a combobox, the UI only appears when you click on the combobox dropdown - if you wanted a grid like layout visible all the time then you would use something like a GridLayout. Without knowing exactly what mySpread is and what it can do or where you get it from it is hard to say what would be a WPF equivalent.

  5. #165
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    I'm gonna come up with an even crazier idea... posting all the content in 1 post!

    Don't mind me today.. I am really trying to avoid work.
    Because the original post (including the quoted content) is too long.

  6. #166
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    That is because they are entirely different things, I am guessing mySpread is a spreadsheet component and a ComboBox.ItemTemplate is a way of changing the appearance of a combobox.

    Plus the WPF example is a combobox, the UI only appears when you click on the combobox dropdown - if you wanted a grid like layout visible all the time then you would use something like a GridLayout. Without knowing exactly what mySpread is and what it can do or where you get it from it is hard to say what would be a WPF equivalent.
    They are completely different things, but they can achieve the same effect (better effect), and the code is simpler and clearer.

    Also, I can easily add a function to mySpread: MyTemplateString = "<ComboBox.ItemTemplate>...</ComboBox.ItemTemplate>"

    The .NET knowledge shown here is already known to Olaf and I, so do everyone here know the knowledge that Olaf and I have shown?
    Last edited by SearchingDataOnly; Feb 2nd, 2021 at 03:12 PM.

  7. #167
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    They are completely different things, but they can achieve the same effect (better effect), and the code is simpler and clearer.

    Also, I can easily add a function to mySpread: MyTemplateString = "<ComboBox.ItemTemplate>...</ComboBox.ItemTemplate>"

    The .NET knowledge shown here is already known to Olaf and I, so do everyone here know the knowledge that Olaf and I have shown?
    You really speak for Olaf a lot, don't you. Why don't you let Olaf speak his own thoughts?

  8. #168
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    36,576

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    Seems to very bluntly state that anyone who cares about code compactness is spewing "nonsense" even though no one has said that compactness is the be-all-end-all.
    You've got a good point there. That WASN'T the last line of my post, but I deleted the rest. That did leave the new 'last line' being too blunt to make a summary.
    My usual boring signature: Nothing

  9. #169
    Frenzied Member PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Newport, UK
    Posts
    1,482

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    They are completely different things, but they can achieve the same effect (better effect), and the code is simpler and clearer.
    But you are comparing a 3rd party component, that isn't actually doing the same thing anyway.

    The WPF sample showed how to do a simple thing, customise the look of a combobox's drop down - that is all. Your example didn't show that, it simply showed some sort of grid component. WPF can also do what your example did, can your example customise a combobox's dropdown appearance?

  10. #170
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    36,576

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    When you start talking about third party components, you really are getting into a pretty weedy area. After all, at that point you are talking about who can create more interesting third party components. That's a highly subjective subject.
    My usual boring signature: Nothing

  11. #171
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by Shaggy Hiker View Post
    When you start talking about third party components, you really are getting into a pretty weedy area. After all, at that point you are talking about who can create more interesting third party components. That's a highly subjective subject.
    My custom combobox class allows ROUND CORNERS! Does yours??

  12. #172
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    But you are comparing a 3rd party component, that isn't actually doing the same thing anyway.

    The WPF sample showed how to do a simple thing, customise the look of a combobox's drop down - that is all. Your example didn't show that, it simply showed some sort of grid component.
    Yes, it was a third-party component (Farpoint Spread) at first, but it was acquired by other companies 10 years ago and it is not continuing to provide new versions. So, I wrote my own Spread component, which is fully compatible with Farpint Spread. Then, it is not a third-party component.

    In addition, Olaf's RC5/RC6 can easily implement similar components.

    Quote Originally Posted by PlausiblyDamp View Post
    WPF can also do what your example did, can your example customise a combobox's dropdown appearance?
    Of course. So, do you think WPF has higher development efficiency than VB6? Obviously not.

  13. #173
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    Of course. So, do you think WPF has higher development efficiency than VB6? Obviously not.
    Those familiar with WPF would have a much higher development efficiency with it than VB6. Just as those familiar with VB6 would have much higher development efficiency with VB6 than WPF.

    Why do you always talk in absolutes?

  14. #174
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    Those familiar with WPF would have a much higher development efficiency with it than VB6. Just as those familiar with VB6 would have much higher development efficiency with VB6 than WPF.

    Why do you always talk in absolutes?
    It's not that I say absolute words. When I said that .NET has no obvious advantages over VB6 in desktop software development, then Niya said I was lying.

    Edit:
    The reason why I often mention Olaf is because I want to talk about a phenomenon I have observed, that is: Olaf's programming knowledge (general programming knowledge) is about 5 times that of mine and 20 times that of Niya.
    Last edited by SearchingDataOnly; Feb 2nd, 2021 at 03:40 PM.

  15. #175
    Frenzied Member PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Newport, UK
    Posts
    1,482

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    Yes, it was a third-party component (Farpoint Spread) at first, but it was acquired by other companies 10 years ago and it is not continuing to provide new versions. So, I wrote my own Spread component, which is fully compatible with Farpint Spread. Then, it is not a third-party component.

    In addition, Olaf's RC5/RC6 can easily implement similar components.


    Of course. So, do you think WPF has higher development efficiency than VB6? Obviously not.
    So show an example of using your component to customise the drop down of a combobox, rather than just putting a grid onto a form. Just a combobox, that when you click on the drop down will display something like Niya's example.

    WPF certainly allows for a richer UI, a more customised UI, and a more flexible UI without needing 3rd party (or in house developed) components than VB6 (or winforms). If we are allowing other components the any WPF grid would be an option to repace your spreadsheet component. Depending on exactly what you are wanting to do you might not even need to develop any extra components with WPF, the built in GridLayout etc. is amazingly powerful.

  16. #176
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    It's not that I say absolute words. When I said that .NET has no obvious advantages over VB6 in desktop software development, then Niya said I was lying.

    Edit:
    The reason why I often mention Olaf is because I want to talk about a phenomenon I have observed, that is: Olaf's programming knowledge (general programming knowledge) is about 5 times that of mine and 20 times that of Niya.

    But that's the thing. .NET has no obvious advantages over VB6 to you. Again, saying .NET has no obvious advantages over VB6 to everyone as your statement implied, is another abolute and cannot be proven to be true.

    Simple advantage of .NET over VB6 for me: I know .NET/C#, I don't know VB6. Thus .NET does have an obvious advantage over VB6 for me.

    That's what I mean by you speaking in absolutes. Everything is subjective.


    And to your edit: so let Olaf show that if he chooses to. You don't need to keep speaking for him.

  17. #177
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    So show an example of using your component to customise the drop down of a combobox, rather than just putting a grid onto a form. Just a combobox, that when you click on the drop down will display something like Niya's example.

    WPF certainly allows for a richer UI, a more customised UI, and a more flexible UI without needing 3rd party (or in house developed) components than VB6 (or winforms). If we are allowing other components the any WPF grid would be an option to repace your spreadsheet component. Depending on exactly what you are wanting to do you might not even need to develop any extra components with WPF, the built in GridLayout etc. is amazingly powerful.
    No need to show more examples and code. In theory, Owner-Drawn can draw any UI.


    https://www.vbforums.com/showthread....=1#post5360185

    https://www.vbforums.com/showthread....=1#post5361187

    https://www.vbforums.com/showthread....=1#post5361193
    Attached Images Attached Images    
    Last edited by SearchingDataOnly; Feb 3rd, 2021 at 04:06 AM.

  18. #178
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    But that's the thing. .NET has no obvious advantages over VB6 to you. Again, saying .NET has no obvious advantages over VB6 to everyone as your statement implied, is another abolute and cannot be proven to be true.

    Simple advantage of .NET over VB6 for me: I know .NET/C#, I don't know VB6. Thus .NET does have an obvious advantage over VB6 for me.

    That's what I mean by you speaking in absolutes. Everything is subjective.


    And to your edit: so let Olaf show that if he chooses to. You don't need to keep speaking for him.
    When I was talking about my own past experience, I mentioned ".NET has no obvious advantages over VB6 in desktop software development", and Niya said I was lying.

    In my opinion, Niya's programming knowledge is very limited, but he said a lot of "absolute words" on the VB6 forum.

  19. #179
    Frenzied Member PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Newport, UK
    Posts
    1,482

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    This may come as a shock, but an owner drawn control can draw any UI even in WPF! Could you owner draw a control, that looks like a combobox, behaves like a combobox, and actually is exactly a combobox, and then make it's dropdown look like the one from Niya's post in a similar amount of lines as the WPF Niya posted?

    Niya posted a simple example of WPF, you responded with something that wasn't doing the same thing and claimed your example was better. Posting links to grid components and talking about owner drawn controls isn't making me think you can easily modify a combobox to behave like the one Niya posted.

  20. #180
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    When I was talking about my own past experience, I mentioned ".NET has no obvious advantages over VB6 in desktop software development", and Niya said I was lying.

    In my opinion, Niya's programming knowledge is very limited, but he said a lot of "absolute words" on the VB6 forum.
    Honestly I think you and Niya just crossed wires then. Looking at your quote right there, it doesn't seem subjective. It seems again like you're stating exactly what you quoted

    .NET has no obvious advantages over VB6 in desktop software development
    If I read that, I wouldn't think you were talking about your own personal opinion and that it has no advantage to you. So maybe Niya thought you were talking in absolutes as well... now that it has been mentioned, I'm sure Niya will come along and state their opinion either way.

  21. #181
    PowerPoster ChrisE's Avatar
    Join Date
    Jun 2017
    Location
    Frankfurt
    Posts
    2,823

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    well one advantage that vb6 has over .Net is the MsFlexgrid = the Merging of Headers

    see this example
    Code:
    Option Explicit
    
    Private Sub Command1_Click()
       Dim i As Long
       Dim mvarYear As Long
       Dim mvarMonth As Long
       Dim Tage As Long
       Dim D As Date
       Dim d1 As Date
       
          mvarYear = Val(Text1.Text) 'Jahr eingabe Format = 2021
          mvarMonth = Val(Text2.Text) 'Monat eingabe = 1 bis 12
          D = DateSerial(mvarYear, mvarMonth, 1)
          
          Tage = Day(DateAdd("m", 1, D) - 1)
          With MSFlexGrid1
          .Redraw = False
             .Rows = 10
             .Cols = Tage + 1
             .FixedRows = 4
             
             d1 = D
             For i = 1 To .Cols - 1
                .TextMatrix(0, i) = MonthName(mvarMonth) & "  " & mvarYear
                .TextMatrix(1, i) = "KW " & KW(d1) 'Kalenderwoche
                .TextMatrix(2, i) = Format(d1, "ddd")
                .TextMatrix(3, i) = i
                 
                 If Weekday(d1, vbMonday) > 5 Then
                   .Col = i
                   .Row = 2
                   .CellForeColor = vbBlue
                   .Row = 3
                   .CellForeColor = vbBlue
            End If
                d1 = d1 + 1
                .ColWidth(i) = 360
                .ColAlignment(i) = flexAlignCenterCenter
             Next
             .MergeRow(0) = True
             .MergeRow(1) = True
             .MergeCells = flexMergeFree
             .Redraw = True
          End With
    End Sub
    
    Public Function KW(ByVal D As Date) As Integer 'DIN 1355/ISO 8601
      D = Int(D)
      KW = (D - 2) Mod 7
      KW = (D - DateSerial(Year(D - KW + 3), 1, KW - 9)) \ 7
    End Function
    
    Private Sub Form_Load()
    Text1.Text = 2021
    Text2.Text = 1
    End Sub
    her a Image
    Name:  FlexKW.jpg
Views: 126
Size:  20.9 KB

    the DataGridview that comes with .Net is a powerfull Grid, but I don't understand why the
    didn't include a Grid with the "Merging" option

    I've never tried WPF, so I don't know if it can be done with WPF
    to hunt a species to extinction is not logical !
    since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.

  22. #182
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    This may come as a shock, but an owner drawn control can draw any UI even in WPF! Could you owner draw a control, that looks like a combobox, behaves like a combobox, and actually is exactly a combobox, and then make it's dropdown look like the one from Niya's post in a similar amount of lines as the WPF Niya posted?

    Niya posted a simple example of WPF, you responded with something that wasn't doing the same thing and claimed your example was better. Posting links to grid components and talking about owner drawn controls isn't making me think you can easily modify a combobox to behave like the one Niya posted.
    Should you review Niya's words: "Can that be done in VB6? Sure it can, but will it be that simple? I'd say probably not."

    At least for me, my method is simpler.

  23. #183
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    33,488

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    Niya said I was lying.
    but he said a lot of "absolute words" on the VB6 forum.
    So are you... on both accounts... but so is he... and so is everyone else in this thread... we're all lying, and we're all talking in absolutes. Heck, I'm doing it now. We're all guilty of it. The key is knowing when to just freaking let it go. Let. it. go. Jeeezes. Life is too short to get into these petty squabbles like this. Ok, so you don't like .NET big whoopty do. don't use it. Don't like. NET. Fine. Don't use it. It's just like gay marriage. Ok, don't like it, don't look. Doesn't stop it from happening, change the channel. It's still going to happen though. Can't stop it. Shouldn't stop it. Doesn't mean you have to like it. Fine what ever. Roll your eyes, let it go, and move on. Seriously. Y'all are .... I don't know... I'm getting to the point of not wanting to come in here any more because of this dreck constantly happening. Honstly, I don't know why I even bother, I don't have a dog in this fight any more. I've moved on. Maybe I need to find a new bar to hang out in.

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  24. #184
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by techgnome View Post
    So are you... on both accounts...
    The old account has been abandoned and cannot log in.

    Quote Originally Posted by techgnome View Post
    but so is he... and so is everyone else in this thread... we're all lying, and we're all talking in absolutes. Heck, I'm doing it now. We're all guilty of it. The key is knowing when to just freaking let it go. Let. it. go. Jeeezes. Life is too short to get into these petty squabbles like this. Ok, so you don't like .NET big whoopty do. don't use it. Don't like. NET. Fine. Don't use it. It's just like gay marriage. Ok, don't like it, don't look. Doesn't stop it from happening, change the channel. It's still going to happen though. Can't stop it. Shouldn't stop it. Doesn't mean you have to like it. Fine what ever. Roll your eyes, let it go, and move on. Seriously. Y'all are .... I don't know... I'm getting to the point of not wanting to come in here any more because of this dreck constantly happening. Honstly, I don't know why I even bother, I don't have a dog in this fight any more. I've moved on. Maybe I need to find a new bar to hang out in.

    -tg
    Maybe you just saw the "quarrel", don't you see the comparison between .NET and VB6? These comparisons are very valuable to many people.

    The "Quarrel" is really terrible, but I don't know how to express my opinions accurately, concisely and politely. But fortunately, all the words I want to say have been said (discourses about .NET and VB6)
    Last edited by SearchingDataOnly; Feb 2nd, 2021 at 04:23 PM.

  25. #185
    Frenzied Member PlausiblyDamp's Avatar
    Join Date
    Dec 2016
    Location
    Newport, UK
    Posts
    1,482

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by SearchingDataOnly View Post
    Should you review Niya's words: "Can that be done in VB6? Sure it can, but will it be that simple? I'd say probably not."

    At least for me, my method is simpler.
    If you consider an owner drawn control easier than a few lines of XML to modify the appearance of an existing control then good for you. Your familiarity with VB6 and lack of familiarity with .Net / WPF is always going to make it easier for you develop in VB6.

    Once you know WPF though you can do some powerful things without having to resort to owner drawn controls and duplicating the behaviour of existing controls.

  26. #186
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    If you consider an owner drawn control easier than a few lines of XML to modify the appearance of an existing control then good for you. Your familiarity with VB6 and lack of familiarity with .Net / WPF is always going to make it easier for you develop in VB6.

    Once you know WPF though you can do some powerful things without having to resort to owner drawn controls and duplicating the behaviour of existing controls.
    I did not use Owner-Drawn in the above code. I just said that my Spread has the feature of Owner-Drawn. RC6.vList also has this feature.

    In addition, I have already said that in 2007, I led the team to develop products with WPF and Silverlight.

    OK, I exit this thread. Sorry to disturb everyone.
    Last edited by SearchingDataOnly; Feb 2nd, 2021 at 04:29 PM.

  27. #187

    Thread Starter
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    6,498

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Whoa you guys have been busy. Currently on a job site right now setting up a client's new business. I'll see if I can respond to some of these when I get home.
    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

    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

  28. #188
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    36,576

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by kfcSmitty View Post
    My custom combobox class allows ROUND CORNERS! Does yours??
    Mine looks like a fish. There's quite a tail behind it, and I'm not quite fin-ished, but at least it scales well.
    My usual boring signature: Nothing

  29. #189
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    36,576

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Maybe you just saw the "quarrel", don't you see the comparison between .NET and VB6? These comparisons are very valuable to many people.
    That's interesting. Why do you feel that way? Personally, I don't think they have any value. It's just that we like to argue. I'd be interested in hearing what value they have.


    I made a quip a couple pages back about the advantage that .NET has over VB6: It can be updated by MS. I kind of feel that's the only significant difference, and you and Olaf have kind of shown that, in case we didn't already know: Given any reasonably complete language, which VB6 certainly is, it is possible to extend it with libraries such that it can accomplish any particular end effectively.

    Those who use .NET can't agree on what is good or bad about it, as this very thread shows. Some like LINQ, some do not. Some like EF, some do not. There may be more ways to 'skin the cat' in .NET than in older languages like VB6, but there are sufficient ways in VB6, so the skinning can be done, and more ways isn't necessarily an advantage.

    So, the only real difference does seem to be: VB6 is frozen in time, .NET can be (and has been, and will be) updated.
    My usual boring signature: Nothing

  30. #190
    PowerPoster
    Join Date
    Sep 2005
    Location
    Modesto, Ca.
    Posts
    4,762

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    So, the only real difference does seem to be: VB6 is frozen in time, .NET can be (and has been, and will be) updated.
    Don't you feel the fact that there is absolutely no life span guarantee for VB6 apps, while currently .Net is supported, though I'm sure not forever, is a significant difference. That's what drove me to .Net @ 10yrs ago. If I'd known MS would have maintained compatibility for another 10+ years, I wouldn't have switched. I'm retired now. lol But I am glad I switched, I learned a lot more about objects and types. I never used a true OO approach in VB6.

  31. #191
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    36,576

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    I don't feel there is much of a guarantee of anything, when it comes to programming. Things come and go. Lots of people on here are actively trying to figure out what the future holds. Nobody has been there yet, though, so we're all just guessing.
    My usual boring signature: Nothing

  32. #192
    PowerPoster
    Join Date
    Sep 2005
    Location
    Modesto, Ca.
    Posts
    4,762

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by Shaggy Hiker View Post
    I don't feel there is much of a guarantee of anything, when it comes to programming. Things come and go. Lots of people on here are actively trying to figure out what the future holds. Nobody has been there yet, though, so we're all just guessing.
    Well sure, if you want to be a fatalist. We're all just going to die anyway. lol

    But MS has not pulled it's support for .Net. There is some guaranteed life span. How long? Then we would be guessing.

  33. #193
    PowerPoster
    Join Date
    Jun 2013
    Posts
    5,612

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by PlausiblyDamp View Post
    Could you owner draw a control, that looks like a combobox, behaves like a combobox, and actually is exactly a combobox,
    and then make it's dropdown look like the one from Niya's post in a similar amount of lines as the WPF Niya posted?
    I thought I answered that already in a prior posting with a simple: "Yes".

    But here's working VB6 Form-Code:

    Base-Setup of the environment (creating the needed Widget-instances):
    Code:
    Option Explicit
    
    Private Panel As cWidgetForm, WithEvents DD As cwDropDown, WithEvents VL As cwVList
     
    Private Sub Form_Load()
      Set Panel = Cairo.WidgetForms.CreateChild(hWnd)
      Set DD = Panel.Widgets.Add(New cwDropDown, "DD", 10, 10, 222, 22)
      Set VL = New cwVList: VL.RowHeight = 33: VL.ListCount = 4
    End Sub
    Private Sub Form_Resize()
      ScaleMode = vbPixels: Panel.Move 0, 0, ScaleWidth, ScaleHeight
    End Sub
    And here's the rest of the Form-Code, which shows the implemented EventHandlers:
    (the first Event demonstrating, how a cwDropDown can show any other Widget-instance in its DropDown-Popup)
    Code:
    Private Sub DD_PopupWidgetRequest(WidgetInstance As Object, WidthPxl As Single, HeightPxl As Single)
      Set WidgetInstance = VL: WidthPxl = 320: HeightPxl = 220
    End Sub
    
    Private Sub VL_OwnerDrawItem(ByVal Index As Long, CC As RC6.cCairoContext, ByVal dx As Single, ByVal dy As Single, ByVal Alpha As Single)
      CC.Rectangle 2, 2, dy - 4, dy - 4
      CC.Fill , Cairo.CreateSolidPatternLng(QBColor(Index))
      
      CC.SelectFont "Segoe UI", 9, QBColor(Index)
      CC.DrawText dy, 4, dx * 0.6, dy - 8, "How it looks as Text", , , 2, 1
      
      Cairo.Theme.DrawTo CC, VL.Widget, thmTypeButtonFace, thmStateHovered, dx * 0.6, 4, dx * 0.3, dy - 8
      VL.Widget.SelectFontSettingsInto CC 'restore orig. Font
      CC.DrawText dx * 0.6, 4, dx * 0.3, dy - 8, "Remove", , vbCenter, 2, 1
    End Sub
    So, again - the simple WPF stuff is equally simple to implement "classically" -
    (with a good drawing-lib in combination with virtual Controls).

    And a small 50-line VB6 example with mid-level complexity was already posted -
    where one would be really hard pressed, to implement it via WPF (.NET-Demo-equivalent still missing).

    HTH

    Olaf

  34. #194
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    A picture is worth 100 sentences. Below is a picture of the results of Olaf's code:

    When there are only 5 lines of code:
    Code:
    Option Explicit
    
    Private Panel As cWidgetForm, WithEvents DD As cwDropDown, WithEvents VL As cwVList
     
    Private Sub Form_Load()
      Set Panel = Cairo.WidgetForms.CreateChild(hWnd)
      Set DD = Panel.Widgets.Add(New cwDropDown, "DD", 10, 10, 222, 22)
      Set VL = New cwVList: VL.RowHeight = 33: VL.ListCount = 4
    End Sub
    Private Sub Form_Resize()
      ScaleMode = vbPixels: Panel.Move 0, 0, ScaleWidth, ScaleHeight
    End Sub
    Attached Images Attached Images  

  35. #195
    Hyperactive Member
    Join Date
    Aug 2020
    Posts
    447

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    A picture is worth 100 sentences. Below is a picture of the results of Olaf's code:

    When adding the rest 10 lines of code:
    Code:
    Private Sub DD_PopupWidgetRequest(WidgetInstance As Object, WidthPxl As Single, HeightPxl As Single)
      Set WidgetInstance = VL: WidthPxl = 320: HeightPxl = 220
    End Sub
    
    Private Sub VL_OwnerDrawItem(ByVal Index As Long, CC As RC6.cCairoContext, ByVal dx As Single, ByVal dy As Single, ByVal Alpha As Single)
      CC.Rectangle 2, 2, dy - 4, dy - 4
      CC.Fill , Cairo.CreateSolidPatternLng(QBColor(Index))
      
      CC.SelectFont "Segoe UI", 9, QBColor(Index)
      CC.DrawText dy, 4, dx * 0.6, dy - 8, "How it looks as Text", , , 2, 1
      
      Cairo.Theme.DrawTo CC, VL.Widget, thmTypeButtonFace, thmStateHovered, dx * 0.6, 4, dx * 0.3, dy - 8
      VL.Widget.SelectFontSettingsInto CC 'restore orig. Font
      CC.DrawText dx * 0.6, 4, dx * 0.3, dy - 8, "Remove", , vbCenter, 2, 1
    End Sub
    Attached Images Attached Images  
    Last edited by SearchingDataOnly; Feb 3rd, 2021 at 03:57 AM.

  36. #196
    Super Moderator FunkyDexter's Avatar
    Join Date
    Apr 2005
    Location
    An obscure body in the SK system. The inhabitants call it Earth
    Posts
    7,716

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Holy wars in -8... -9... -10...


    Couple of lifetimes ago, there was some code I had to delve into because it wasn't working. Turned out it was because the original developer had tried to use LINQ w/o fully understanding what they were doing and how delayed execution worked.
    I'm guessing you're really talking about Entity Framework rather than Linq (I'm making that guess on the basis that you talk about delayed execution and that I've had to pull apart loads of bad EF implementations). I really think MS completely miss-sold EF. All the messaging was "you don't need to understand databases or how to optimise query execution anymore" but EF/Linq/LinqToSQL really don't save you that - you still need to know what you're doing.

    The worst habit EF had was when you used aggregate queries. It would pull the entire dataset back and then aggregate it client side which was a crazy implementation but thankfully they finally fixed that in core. Couple that with people not understanding the implications of eager and lazy loading and you've got a recipe for lots of inefficient queries that need to be revisited by a DBA.

    In fact, I think we could all take an object lesson from this when we're talking about third party frameworks etc. Any time you use a third party component you're putting a level of abstraction between yourself and the execution. That can be hugely valuable in simplifying your code but it doesn't excuse you from the need to understand what's actually happening under the lid.
    The best argument against democracy is a five minute conversation with the average voter - Winston Churchill

    Hadoop actually sounds more like the way they greet each other in Yorkshire - Inferrd

  37. #197

    Thread Starter
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    6,498

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Wow...you guys have been such busy bees.

    After coming back from the job site last night I decided to take a small break. A break from VBForums, a break from programming. I ate, watched some TV and went to bed. Sometimes taking a short break from something really is good. It gave me time to think about why we seem to be going round and round. Why is it we seem so unable to communicate effectively why us here on the .Net side of the fence much prefer modern Visual Studio editions over archaic VB6. I realized that we've been going about this all wrong. You see when you get right down to it, what we really love about modern Visual Studio is the little things that add up to a much more productive development experience. Now we can post code until we're blue in the face it effectively communicates nothing. The problem is that words cannot communicate what a more productive development experience really means. Words are the wrong tool for the job. You see if I post something in VB.Net and Olaf posts how he did the same thing in VB6, all it shows is that it can be done. We don't see how each of us got there. We don't see the experience of writing the code.

    So I came up with an idea. You could say I had an epiphany yesterday. There is a way to show people exactly what we are talking about. There is a tool that we can use. It's not words, it's images. Video to be exact. So here's what I'm going to do. I've decided to write an application. Nothing fancy, just a small application, something that represents what most people might be working on. I'm kind of settled on a very simplistic CRUD application but I may not decide that in the end but that's probably what I'll go with. I will write the application twice from start to finish, once in VB6 and once in VB.Net/WPF. The idea is that the video will capture the experience of developing the application in both environments. I'm hoping it will show how all the little things like language features, IDE features, the immediate availability and robustness of the .Net Framework come together to create a better development experience.

    Now I'm going to hold myself to a couple rules so that it is a realistic demonstration of application development. The big one is no copy-paste of large pre-arranged pieces of code to cheat the experiment. The second rule is that the demonstration MUST begin with the creation of a blank Visual Studio project. So no starting the project after importing libraries, Win32 APIs etc. all that goes into the development experience and it must be shown. Now I'm going to allow myself some preparation so I don't end up with lengthy periods where I'm trying to remember how to do this or that. I want it to be one straight run from start to finish with no kind of pauses where I have to google something or struggle to get something to work because I didn't quite remember how to do it.

    Now I want to be clear, my goal is not to convince anyone not to love VB6 or give it up. It never was. It is just to show you what we see and give you an idea of why we say the things we say. I don't expect fences to be mended by this. To be honest I don't even know how this little experiment would affect the discussion. I just hope it will bring us all on whatever side of the fence we sit closer to understanding each other.

    Now I have never done this kind of thing. I'm not a social media guy. I don't know anything about recording videos or uploading them or any of that. I don't do TikTok and I only ever watch YouTube. So before I do this, I'm going to have to look for some screen recording software, learn how to use it, how to upload it ect. It's gonna be a spell before I actually do this. I'm gonna have to give myself a crash course on this. Hopefully it won't take too long and we can get this ball rolling.
    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

    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

  38. #198
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Not sure that is worth your time or effort unless you want to do it for your own benefit (or I suppose to save a lot of typing the next time this subject comes up).

    Those still in VB6 are there because they have been using it a long time. They have no interest in changing to another language, no matter how much faster you show it is for development for you.

    They seem to fall into a few camps:

    1) They care about source code security
    2) Performance is ultimate for them. .NET can deal with this mostly, but if you're new, it is a big learning curve to learn a new language plus all the little intricacies needed to know how to speed something up can be a lot to learn

    I had more in my head, but they're escaping me now.. it's too early.

    Mostly I think it is that they've been in VB6 for a long time, are efficient in it, and are able to do what they need to do quickly with it. Sure, the language is unsupported and they may be screwed at "any time", but people have been saying that for what? 15 years now? And it still hasn't come to fruition. Assuming someone started with VB6 right as .NET came out, they're halfway to retirement already and all of the talk about learning a dead language that will bite them in the butt hasn't really come true.

    I think these threads get so many replies because people don't qualify their posts enough. Everyone talks in absolutes that X is faster than Y, or X is more efficient than Y. But maybe XML is more intuitive for you for layout than writing code to do it. Maybe you work somewhere that only deals with thousands or hundreds of thousands of records, and not millions, so that efficiency in language X to process that many records is irrelevant to you.

    What user X sees as a downside of one language literally may not matter to user Y at all. I definitely know certain users make a point of looking and talking down to those who don't agree with them, and that definitely doesn't help the general attitude in these threads.

  39. #199
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    33,488

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Quote Originally Posted by FunkyDexter View Post
    Holy wars in -8... -9... -10...


    I'm guessing you're really talking about Entity Framework rather than Linq (I'm making that guess on the basis that you talk about delayed execution and that I've had to pull apart loads of bad EF implementations). I really think MS completely miss-sold EF. All the messaging was "you don't need to understand databases or how to optimise query execution anymore" but EF/Linq/LinqToSQL really don't save you that - you still need to know what you're doing.

    The worst habit EF had was when you used aggregate queries. It would pull the entire dataset back and then aggregate it client side which was a crazy implementation but thankfully they finally fixed that in core. Couple that with people not understanding the implications of eager and lazy loading and you've got a recipe for lots of inefficient queries that need to be revisited by a DBA.

    In fact, I think we could all take an object lesson from this when we're talking about third party frameworks etc. Any time you use a third party component you're putting a level of abstraction between yourself and the execution. That can be hugely valuable in simplifying your code but it doesn't excuse you from the need to understand what's actually happening under the lid.
    Holy war... denied...

    No, believe it or not, it wasn't EF... The issues with that I know too well, which is why I never got around to using it until more recently. In this case though, EF wasn't even an option - it wouldn't be released for another year... I remember heading down the street to a theater to a conference where EF was announced and demoed for us. We were using custom queries with typed datasets, and I made the usual mistake - conflating (right word?) LINQ and Lambas - it was the lambdas with LINQtoObjects that was the issue. The cases were we were seeing the problem was where we were (try saying that five times real fast) pulling back the typed dataset, then filtering a typed datatable to loop through the results. Who ever wrote the code originally was trying to do a ForEach on the same line as the .Select.Where.And.So.On.Etc In the process of debugging and checking things, I found that it was just flying right over the ForEach loops... when I then sent the results to a List<> variable first to see why it was empty, it started going into the loops... AWRROOOO? I had to go back and rewrite several dozens of loops that had been written like that. Took me a couple days. The fun ones were the filtered filtered results.

    Crazy times.

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  40. #200
    Hyperactive Member
    Join Date
    Jun 2019
    Posts
    351

    Re: Why is VB.Net/C#/XAML + VS2019 is better than VB6? Here's why.....

    Anyone around ever opened "stackoverflow.com" site? Or ever been redirected by google search there? It was written by ex-VB6ers...

Page 5 of 18 FirstFirst ... 234567815 ... LastLast

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