dcsimg
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

View Poll Results: Why VB 6.0

Voters
25. You may not vote on this poll
  • My employer/school requires it - and provides a valid licensed copy

    7 28.00%
  • My employer/school requires it - I dont know if I am legal

    2 8.00%
  • Been using if for years legally and see not reason to upgrade to (free) new version

    13 52.00%
  • Got a copy of it from somewhere..

    4 16.00%
  • I didn't know any better

    1 4.00%
  • I am a caveman...

    7 28.00%
Multiple Choice Poll.
Page 28 of 29 FirstFirst ... 182526272829 LastLast
Results 406 to 420 of 422

Thread: Why VB 6.0??

  1. #406
    Join Date
    Aug 2005
    Location
    Imperial College London, England
    Posts
    490

    Re: Why VB 6.0??

    Sorry about the "ABC". I haven't had enough sleep

    I've just run the same test as you, both with the listbox visible and hidden. I was very careful about form and control sizes for the visible one, so that the paint region was the same. I've taken averages across a number of runs (as this thing is becoming slightly jerking due to encoding mp3s...)

    It was all done form a Compiled exe. Not using the debugger.

    Results:
    Visible:
    Vb.Net: 156ms (ranged from 110 - 172, including 5 172s out of ten runs)
    vb6: 106ms (range 78 - 165, including 4 94s out of ten runs)

    Hidden (NOTE: NOT THE SAME NUMBER OF RUNS!)
    Vb.net 528ms little range
    vb6 I got bored after about 30seconds...so one run was 38953.
    Help from me is always guaranteed!*
    VB.NET code is made up on the spot with VS2008 Professional with .NET 3.5. Everything else is just made up on the spot.
    Please Remember to rate posts, use code tags, send me money and all the other things listed in the "Before you post" posts.

    *Guarantee may not be honoured.

  2. #407
    Join Date
    Jun 2008
    Posts
    592

    Re: Why VB 6.0??

    No problem. Could you download the listbox_speed.zip and run them both compiled without any modification, so we can get a more solid ground on results. EDIT: I want you because I did modify code a bit, so your code is no longer the same size on both the gui or coding wise
    Last edited by Joeman; July 22nd, 2008 at 02:54 PM.
    0100 0111 0110 1111 0110 0100 0010 0000 0110 1001 0111 0011 0010 0000 0110 0110 0110 1111 0111 0010
    0110 0101 0111 0110 0110 0101 0111 0010 0010 0001 0010 0001 0000 0000 0000 0000
    0000 0000 0000 0000

  3. #408
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    okay so i did much the same for the Sorting Algo's...

    I did a quick rewrite of the VB6 code into VB.NET, and the results are some what interesting....

    VB6 left, VB.NET right...


    NOW... Some notes...

    1) The sorting is done directly within the Listbox...
    2) None of the code has been optimised..
    3) Sorting times are also dependant on how out out of sort the array is, and it's a little beyond thescope of this test to try and give both test apps the same list..

    Anyone care to interpret these results, and perhaps tweek the code...
    Attached Files Attached Files
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  4. #409
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    Quote Originally Posted by WizBang
    This is very interesting Gremmy!

    So, what do you suppose accounts for the differences between the differences? LOL I mean, the .net version is about twice the speed this time, whereas drawing boxes was relatively close.
    What i've been thinking is that .NET has an Updated maths object, something a lot faster, taking advantage of some of the new Chip features..

    For example, VB6's "K = K + 1" can be translated to "K += 1"...

    That's about all I can figure...
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  5. #410
    Join Date
    Jun 2008
    Posts
    592

    Re: Why VB 6.0??

    I downloaded you code for sorting, but I couldn't test the vb6 version because I couldn't find it in there. Did you Post the vb6 version?
    0100 0111 0110 1111 0110 0100 0010 0000 0110 1001 0111 0011 0010 0000 0110 0110 0110 1111 0111 0010
    0110 0101 0111 0110 0110 0101 0111 0010 0010 0001 0010 0001 0000 0000 0000 0000
    0000 0000 0000 0000

  6. #411
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    Quote Originally Posted by Joeman
    I took the ideal to use a lisbox to see how fast vb6 and vb.net can populate the listbox.

    The results are:

    vb6 - 907 ms
    vb.net - 2218 ms
    This one i think may be a little easier to explain..

    The Listbox Item object in VB6 is smaller than the VB.NET object.. In .NET it uses more memory, and hence takes longer to create/Allocate the memory..

    Look at the sorting algo's test to see what i'm saying...
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  7. #412
    Join Date
    Jun 2008
    Posts
    592

    Re: Why VB 6.0??

    At least this explains why some people call the gui part slower. It makes alot more since now.

    EDIT: I am referring to locked and delayed window components on the window
    0100 0111 0110 1111 0110 0100 0010 0000 0110 1001 0111 0011 0010 0000 0110 0110 0110 1111 0111 0010
    0110 0101 0111 0110 0110 0101 0111 0010 0010 0001 0010 0001 0000 0000 0000 0000
    0000 0000 0000 0000

  8. #413
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    Quote Originally Posted by Joeman
    I downloaded you code for sorting, but I couldn't test the vb6 version because I couldn't find it in there. Did you Post the vb6 version?
    The original VB6 code is in this article

    The VB6 code has been pretty much tweeked, short of sorting in the Listbox. This was done on purpose, to enable the 'display sort progress', and a few other things...
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  9. #414
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    Okay i spent a little time checking the code and found a few things..

    1) in a few places I put "If Prog.Checked = 1 Then", this takes longer to execute than "If Prog.Checked Then", which is what it was suposed to be..

    2) changing the declaration of "S_Temp" to "Integer" instead of "Object" in the Swap Sub looks to help speed it up..

    New times for .NET with these changes.. from the top.. 11622ms, 3822ms, 2106ms, 1045ms, 249ms, 483ms, 359ms...
    Last edited by GremlinSA; July 22nd, 2008 at 03:41 PM.
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  10. #415
    Join Date
    Sep 2001
    Location
    Québec, Canada
    Posts
    1,923

    Re: Why VB 6.0??

    Care if I add a speed test of mine? It's pure calculation and the results are pretty interesting. Now, see if you can tweak some compilation parameters or some code parameters and even the things out. Maybe testing with the unsafe keyword (for the c# app) could make things faster?

    Anyway, the .zip file include the code for c++, vb6, c# and vb.net and the results I got on my computer. Do you get similar results?

    JeffB
    Attached Files Attached Files
    CodeGuru VB FAQ Visual Basic Frequently Asked Questions
    VB Code color Tool to color your VB code on CodeGuru
    Before you post Importants informations to know before posting

  11. #416
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,171

    Re: Why VB 6.0??

    Wow, look at all these trees. What is this place?

  12. #417
    Join Date
    Dec 2001
    Posts
    6,332

    Re: Why VB 6.0??

    Quote Originally Posted by GremlinSA
    What i've been thinking is that .NET has an Updated maths object, something a lot faster, taking advantage of some of the new Chip features..

    For example, VB6's "K = K + 1" can be translated to "K += 1"...

    That's about all I can figure...
    I was wondering about that, but also about the speed of the graphics object that you used in the .net version for drawing the squares. Perhaps the more graphics work the code must do, the slower .net would become relative to the VB6 code using API.

    So it might prove insightful to test a routine which checks the properties of a bunch of controls, such as buttons, checkboxes, dropdowns, etc. As long as it doesn't change any properties, the controls won't need to be redrawn, so it should give some idea of how efficiently the objects are accessed.

    But, before I write that, I'll post the sorting test I slapped together earlier. This uses BubbleSort, and the CheckBox determines whether the array to be sorted is numeric or string. (the original button and code is still there too). A ListBox is included to show multiple test results.
    Attached Files Attached Files
    Please remember to rate the posts and threads that you find useful.
    How can something be both new and improved at the same time?

  13. #418
    Join Date
    Jun 2005
    Location
    JHB South Africa
    Posts
    3,772

    Re: Why VB 6.0??

    Okay i've started a whole bank of threads in the CODE WAR forum, and think it'll be better to take these tests there...

    This is the control thread which will have links to each of the individule tests .. I think it is important to keep each test in a seperate thread to minimise the cross test comparison...
    Articles VB6 : Break the 2G limit - Animation 1, 2 VB.NET : 2005/8 : Moving Images , Animation 1 , 2 , 3 , User Controls
    WPF Articles : 3D Animation 1 , 2 , 3
    Code snips: VB6 Hex Edit, IP Chat, Copy Prot., Crop, Zoom : .NET IP Chat (V4), Adv. ContextMenus, click Hotspot, Scroll Controls
    Find me in ASP.NET., VB6., VB.NET , Writing Articles, My Genealogy, Forum
    All VS.NET: posts refer to VS.NET 2008 (Pro) unless otherwise stated.

  14. #419
    Join Date
    Aug 2003
    Location
    Sydney, Australia
    Posts
    1,879

    Re: Why VB 6.0??

    Perhaps one of the questions should have been

    "Why VB.Net ?"

    http://www.adit.co.uk/html/vb7rant.html

    http://www.geocities.com/tablizer/oopbad.htm

  15. #420
    Join Date
    Aug 2005
    Location
    Imperial College London, England
    Posts
    490

    Re: Why VB 6.0??

    Indeed.
    Having now worked with both, I really think a VB7 might STILL be needed. The only features of .NET i've liked are Docking and the proper classes. Oh, and the ability to (if a bit messily and difficultly) deal with pointers. None of these, however, rely on the .NET framework...
    Help from me is always guaranteed!*
    VB.NET code is made up on the spot with VS2008 Professional with .NET 3.5. Everything else is just made up on the spot.
    Please Remember to rate posts, use code tags, send me money and all the other things listed in the "Before you post" posts.

    *Guarantee may not be honoured.

Page 28 of 29 FirstFirst ... 182526272829 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
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width




On-Demand Webinars (sponsored)