dcsimg
Results 1 to 15 of 15

Thread: Win10 AppCompat VB6 IDE

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Lightbulb Win10 AppCompat VB6 IDE

    Since there is no code here, this didn't seem to make sense for the CodeBank. It is only of interest to VB6 programmers so General Discussions didn't seem to fit either.


    Once people get VB6 installed they often struggle with the little tweaks required. Often people will use one of the Windows Version Compatibility Modes, but those have undesirable shims bundled into them such as version-lies.

    I realize that few VB6 programmers have installed or used the Application Compatibility Toolkit, so I thought I'd post a custom Shim Database (.sdb) file. I have included two versions, but one pattern-matches on a specific patch level and will become obsolete as Microsoft releases VB6.exe patches (which do actually still occur though rarely):

    Name:  VB6 Capture orig.png
Views: 2083
Size:  11.2 KB

    Original

    Because of that I've included a less restrictive version as well. Sadly there is no support for wild-carding in versioning values so it might also match another program, but the risk is probably quite low:

    Name:  VB6 Capture.png
Views: 2043
Size:  8.4 KB

    Less restrictive

    That's the one you'd want to use. The attachment includes Install.cmd and Uninstall.cmd for that one.

    To run the install you can right-click and Run as administrator and that's all there is to it. You can even do that before installing VB6 itself.


    It seems to work fine in Windows 10 (Threshold 2, i.e. current level of patches to Windows 10) though I can't say regarding Windows 10 after the Redstone "Anniversary Update" patches coming in August 2016.

    This set of shims addresses the DWM issues that can cause Designer-drag lagging in the IDE. Weirdly enough, you get a red rubberband when stretching, sizing, etc. but it works just fine. It also has RunAsAdmin.

    I was a little doubtful about the HighDpiAware shim, but it seems ok so far.

    This has been working great for me. It might also work unchanged for Windows 8.1, Windows 8, and even Windows 7 for all I know.

    Avoiding the version-lie shims means you have access to APIs and ActiveX components you'd be denied otherwise. Of course for some you'll still need a manifest embedded into VB6.exe to get Common Controls 6.x access and you may also want to add <supportedOS /> elements as well for full access to new APIs. But the application manifest for VB6.exe is another topic.
    Attached Files Attached Files

  2. #2

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    As far as I can tell what this changes in the registry looks like:

    Code:
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\InstalledSDB\{fbc6500a-a183-415c-9aa5-f67b9c1536a7}]
    "DatabasePath"="C:\\Windows\\AppPatch\\Custom\\{fbc6500a-a183-415c-9aa5-f67b9c1536a7}.sdb"
    "DatabaseType"=dword:00010000
    "DatabaseDescription"="VB6 shims"
    "DatabaseInstallTimeStamp"=hex(b):fc,2f,54,19,81,e9,d1,01
    
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Custom\VB6.EXE]
    "{fbc6500a-a183-415c-9aa5-f67b9c1536a7}.sdb"=hex(b):fc,2f,54,19,81,e9,d1,01

  3. #3

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    There is nothing executable there so no reason to censor it any more than an image file.

  4. #4
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,301

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by Elroy View Post
    Since, strictly speaking, your attachments aren't ASCII/ANSI files, I'll be surprised if the moderators let it stand.
    We do allow a variety of non-ascii files (such as Excel based files), but some need to be zipped first as we do not have them specified in the allowed list of the forum software (there are a variety of reasons for that, such as file size, and the fact we don't want to manage the list frequently).

    While I haven't opened the .sdb files in a proper viewer, they seem fine after a quick check in Notepad.

    Given dilettante's long history here, and the high moral standards he has shown, it is safe to assume the attachment will not be removed by moderators unless we are given a good reason to do so.

  5. #5

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    Thanks for the vote of confidence. The .SDB files should be viewable using almost any version of the ACT's Compatibility Administrator tool. I'm not sure what format they're in and may be a simple ESENT database or something.

  6. #6
    Fanatic Member
    Join Date
    Jan 2006
    Posts
    557

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by si_the_geek View Post
    Given dilettante's long history here, and the high moral standards he has shown...
    More catholic than that, Pope Francis would be out of a job

  7. #7

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    I'm starting to worry about being awarded a gold-tone Dollar Store pocket watch (As Seen on TV!) and nudged out the door to pasture.

  8. #8

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    Not directly related but easily forgotten when reinstalling on a fresh Win10 system:

    If you normally use the IDE in MDI mode, opening a Project with windows maximized can be handy. I know I'm used to it and missed it.


    Make a file called something like VB Open Maximized.reg and paste in:

    Code:
    Windows Registry Editor Version 5.00
    
    [HKEY_CURRENT_USER\Software\Microsoft\Visual Basic\6.0]
    "MDIMaximized"="1"
    Then you can right-click and choose Merge.

  9. #9

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    Well I have found a glitch in that .SDB for VB6.exe:

    When you multi-select several controls in the Form designer (probably UserControl as well) you select them and can drag the group... but this multi-selection isn't visually indicated.

    In other words it looks like you haven't selected any of them. Normally you get a box around them but it isn't appearing.


    This isn't major but it is worrying and less than adequate, and I'm sure we can do better. Perhaps it relates to the strange red rubberband line?

    I'll see if I can find a fix for that.

  10. #10
    Fanatic Member
    Join Date
    Apr 2015
    Location
    Finland
    Posts
    658

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by dilettante View Post
    When you multi-select several controls in the Form designer (probably UserControl as well) you select them and can drag the group... but this multi-selection isn't visually indicated.

    In other words it looks like you haven't selected any of them. Normally you get a box around them but it isn't appearing.
    Same behaviour as with common control 6.0 manifested ide (vb6.exe file). Selecting more than one control, the selection/selected indicators disappear altogether. Also in manifested ide form/control properties (back-, fore- etc.) color dialog 'palette', is shown as blank white.

  11. #11

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    Hmm, I know about the color dialog issue with a CC6 manifest applied to the IDE. I must have forgotten that it also causes multi-select to lose the indicators.

    This .SDB doesn't seem to result in the other problems we have with a CC6 manifest: things like the color dialog problem and Option buttons in a Frame being blacked out.

  12. #12

    Thread Starter
    PowerPoster
    Join Date
    Feb 2006
    Posts
    20,805

    Re: Win10 AppCompat VB6 IDE

    I still have not found a fix for the multi-selected controls indication. However I have eliminated a number of shims we don't need in this new version:

    Name:  VB6 Capture.png
Views: 1932
Size:  6.3 KB
    Attached Files Attached Files

  13. #13
    VB-aholic & Lovin' It LaVolpe's Avatar
    Join Date
    Oct 2007
    Location
    Beside Waldo
    Posts
    18,576

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by dilettante View Post
    Hmm, I know about the color dialog issue with a CC6 manifest applied to the IDE. I must have forgotten that it also causes multi-select to lose the indicators.
    Here's something I just discovered the other day regarding CC6 manifest and the IDE. Adding single character listbox/combobox items in the listbox/combobox property window fails. We get a square character instead (at least on Win10).
    Insomnia is just a byproduct of, "It can't be done"

    Classics Enthusiast? Here's my 1969 Mustang Mach I Fastback. Her sister '67 Coupe has been adopted

    Newbie? Novice? Bored? Spend a few minutes browsing the FAQ section of the forum.
    Read the HitchHiker's Guide to Getting Help on the Forums.
    Here is the list of TAGs you can use to format your posts
    Here are VB6 Help Files online


    {Alpha Image Control} {Memory Leak FAQ} {Unicode Open/Save Dialog} {Resource Image Viewer/Extractor}
    {VB and DPI Tutorial} {Manifest Creator} {UserControl Button Template} {stdPicture Render Usage}

  14. #14
    New Member
    Join Date
    Jun 2018
    Posts
    1

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by LaVolpe View Post
    Here's something I just discovered the other day regarding CC6 manifest and the IDE. Adding single character listbox/combobox items in the listbox/combobox property window fails. We get a square character instead (at least on Win10).
    For kindness The LaVolpe; how did you solve this unique character problem in the listbox?

  15. #15
    VB-aholic & Lovin' It LaVolpe's Avatar
    Join Date
    Oct 2007
    Location
    Beside Waldo
    Posts
    18,576

    Re: Win10 AppCompat VB6 IDE

    Quote Originally Posted by schmitz View Post
    For kindness The LaVolpe; how did you solve this unique character problem in the listbox?
    Simply populate the listbox in Form_Load, i.e., List1.AddItem "C"
    Insomnia is just a byproduct of, "It can't be done"

    Classics Enthusiast? Here's my 1969 Mustang Mach I Fastback. Her sister '67 Coupe has been adopted

    Newbie? Novice? Bored? Spend a few minutes browsing the FAQ section of the forum.
    Read the HitchHiker's Guide to Getting Help on the Forums.
    Here is the list of TAGs you can use to format your posts
    Here are VB6 Help Files online


    {Alpha Image Control} {Memory Leak FAQ} {Unicode Open/Save Dialog} {Resource Image Viewer/Extractor}
    {VB and DPI Tutorial} {Manifest Creator} {UserControl Button Template} {stdPicture Render Usage}

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width