Results 1 to 12 of 12

Thread: [RESOLVED] VB3 to VB6 - Sheridan 3D Controls

  1. #1

    Thread Starter
    Member MorkenTheMonk's Avatar
    Join Date
    Sep 2017
    Location
    Scotland, UK
    Posts
    42

    Resolved [RESOLVED] VB3 to VB6 - Sheridan 3D Controls

    First attempts at moving old VB3 project across to VB6 (without VB4/5 in between). I've no doubt this'll be the first of many questions on here!

    Apart from having to move across some unsupported .VBX files, and converting some Binary forms/modules to Text instead, here's my first real problem...

    I've encountered 3D Radio Buttons (SSOption controls - Sheridan!?) used extensively in some of the Forms, and VB3 automatically converts them to PictureBox controls !?

    Firstly, in VB3 these SSOption Objects all feature a parameter 'Value as Integer' in their Click procedure. This can be relatively easily overcome by removing the parameter in the imported VB6 code. Most of these Radio Buttons seem to switch various variables True or False anyway.

    Secondly, and more importantly, does anyone know of a way to either convert these PictureBox controls back to OptionButtons, or have VB6 recognise the SSOption buttons in the first place?

    All advice will be gratefully received. Thanks in advance.
    __________________________________________________________________________________________
    MorkenTheMonk
    SCOTLAND

    (Stuck supporting a 16-bit VB3 application over 20 years old! Deep Joy!!!)

  2. #2
    PowerPoster Elroy's Avatar
    Join Date
    Jun 2014
    Location
    Near Nashville TN
    Posts
    9,852

    Re: VB3 to VB6 - Sheridan 3D Controls

    Hi Morken,

    I'm digging deep into the memory banks here, but I'll try and help as much as I can.

    First, it's probably a mistake to try and "convert these PictureBox controls back to ...". It'd be much better if we could figure out how to make the project load in the first place. In other words, reload the VB3 project but have the new VB6 project setup to better handle things.

    I know you made backups of your source code before you started this, so I won't even ask.

    Regarding the Sheridan controls, I'm just certain there was a VB6 (32-bit) version of them. However, getting your hands on them at this date might be a bit problematic. I'll look around and see what I've got. And, just to say it, I think most of us abandoned any use of those things long ago (with the possible exception of the SSTab control, which Microsoft bought and incorporated into the core VB6 package).


    Also, how are you bringing things over (from VB3 to VB6)? A few more details on that could be very helpful.

    Best Regards,
    Elroy
    Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.

  3. #3
    PowerPoster Elroy's Avatar
    Join Date
    Jun 2014
    Location
    Near Nashville TN
    Posts
    9,852

    Re: VB3 to VB6 - Sheridan 3D Controls

    Okay, most of the old Sheridan controls seem to come with the VB6 IDE. However, apparently they're not necessarily installed along with the rest of the IDE. If you get your VB6 IDE installation disks, you should find a file named THREED32.OCX under root\Common\Tools\VB\Controls.

    You can just manually install that file by copying it to your c:\Windows\System32 (or c:\Windows\SysWOW64 if you're on a 64-bit Windows system). And then, from a CMD prompt, navigate to that folder and type something like: regsvr32 threed32.ocx

    And then, when you start the VB6 IDE, and then go under Components (menu/Project/Components...), you should see an entry for "Sheridan 3D Controls". Add that to your project, and then those Sheridan controls should start working on VB6 forms. If you're just dragging your .FRM and .BAS modules across, just be sure and add this component before starting.

    Good Luck,
    Elroy

    EDIT1: If the Sheridan controls aren't in the project first, you'll still get those pictureboxes.
    Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.

  4. #4
    gibra
    Guest

    Re: VB3 to VB6 - Sheridan 3D Controls

    Quote Originally Posted by MorkenTheMonk View Post
    I've encountered 3D Radio Buttons (SSOption controls - Sheridan!?) used extensively in some of the Forms, and VB3 automatically converts them to PictureBox controls !?
    Perhaps you wanted to write that VB6 converts them into PictureBox (not VB3)

    Honestly, it's been a long time since I was using VB3, so I no longer have the conversion situation. I should see a couple of forms (already converted to text) to give you more precise directions.
    If the problem is only the RadioButton, then it should not be difficult to replace them with normal OptionButtons, obviously making a replace BEFORE converting the project into VB6.0

  5. #5
    PowerPoster Elroy's Avatar
    Join Date
    Jun 2014
    Location
    Near Nashville TN
    Posts
    9,852

    Re: VB3 to VB6 - Sheridan 3D Controls

    Also, if you post one of your .FRM files (in its entirety, possibly zipped), I'll try it here for you. In VB3, it's likely that those .FRM files are saved as binary (i.e., not ASCII). However, if I remember correctly, there's a way (under something like Project/Properties) to tell it to save them as ASCII.

    If you can get your .FRM files saved as ASCII and then call it up with Notepad, you could then post it here so I (and others) could figure out the easiest steps to get it converted.

    Best Regards,
    Elroy
    Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.

  6. #6

    Thread Starter
    Member MorkenTheMonk's Avatar
    Join Date
    Sep 2017
    Location
    Scotland, UK
    Posts
    42

    Re: VB3 to VB6 - Sheridan 3D Controls

    Thanks Elroy, completely new to VB6 so forgive me if I'm making assumptions / obvious mistakes.

    Installed a copy of VB6 Enterprise on a Windows7 64-bit machine, environment seems to run fine. Took a complete copy of my VB3 source code (safely tucked away inside an XP VM) and copied over to a new folder in Win7. Attempted to open the original .MAK project file in VB6, which resulted in numerous error messages (missing VBX's, Binary format, .LOG files, etc)

    I've now moved the VB3 .VBX files in question into my Win7 System folder - that problem solved. Used VB3 to 'Save as Text' the Binary files (.FRM, .BAS) in question, and copied them over to Win7 environment - solved. Project now loads in VB6, and able to view the Forms, Code, and Modules.

    Hitting PLAY to run the application instantly gives me a Compile error - this is what led me to examine the Object causing the error, and thus discovered that my SSOption button had been converted to a PictureBox by VB6!

    Completely agree that it would be perfect to have VB6 open the original code (copy) without having to re-program each of the affected Controls/Objects. Similarly, I could convert each of the SSOption controls in VB3 to 'standard' radio buttons, then copy that over to VB6 environment - sadly though, this would also mean re-programming each of the controls.

    Hope that's not too much detail Elroy.
    __________________________________________________________________________________________
    MorkenTheMonk
    SCOTLAND

    (Stuck supporting a 16-bit VB3 application over 20 years old! Deep Joy!!!)

  7. #7

    Thread Starter
    Member MorkenTheMonk's Avatar
    Join Date
    Sep 2017
    Location
    Scotland, UK
    Posts
    42

    Re: VB3 to VB6 - Sheridan 3D Controls

    Quote Originally Posted by gibra View Post
    Perhaps you wanted to write that VB6 converts them into PictureBox (not VB3)
    You are quite correct Sir, my fat slow fingers not keeping up with my slightly less fat, slightly quicker brain!
    __________________________________________________________________________________________
    MorkenTheMonk
    SCOTLAND

    (Stuck supporting a 16-bit VB3 application over 20 years old! Deep Joy!!!)

  8. #8
    PowerPoster Elroy's Avatar
    Join Date
    Jun 2014
    Location
    Near Nashville TN
    Posts
    9,852

    Re: VB3 to VB6 - Sheridan 3D Controls

    Quote Originally Posted by gibra View Post
    If the problem is only the RadioButton, then it should not be difficult to replace them with normal OptionButtons, obviously making a replace BEFORE converting the project into VB6.0
    Yeah gibra, I thought of that too, but I've got no idea how many times he's used the old Sheridan controls. So I've got no idea how much work that would be.

    Yes, Morken, I'm glad you got things saved as "Text". That "binary save" was an early attempt to save a bit of disk space (back when that really mattered), and was abandoned (for only Text saving) sometime shortly after VB3.

    I've got no idea how involved your project is, but here's an idea:
    1. start a new VB3 project
    2. place a couple of Sheridan controls on a single form
    3. make sure it'll run
    4. save everything as Text
    5. zip up the project
    6. post it here (i.e., attach it to a post, under Go Advanced, paperclip button)


    That way, we can try to help more.

    Good Luck,
    Elroy
    Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.

  9. #9
    Smooth Moperator techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,531

    Re: VB3 to VB6 - Sheridan 3D Controls

    Quote Originally Posted by MorkenTheMonk View Post

    Hitting PLAY to run the application instantly gives me a Compile error - this is what led me to examine the Object causing the error, and thus discovered that my SSOption button had been converted to a PictureBox by VB6!
    That's what VB does when it encounters a control it cannot load or doesn't find on the system. In short, the Sheridan Controls Liberary isn't installed, or if it is, VB can;t find the reference to them. So it does the safgest thing it knows how to do and changes the controls into picture boxes.

    -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??? *

  10. #10

    Thread Starter
    Member MorkenTheMonk's Avatar
    Join Date
    Sep 2017
    Location
    Scotland, UK
    Posts
    42

    Re: VB3 to VB6 - Sheridan 3D Controls

    Elroy / Gibra ... we are making progress thanks to your suggestions!

    Went off to hunt for THREED32.OCX and discovered that it was already present in Windows\SysWOW64 (therefore VB6 Enterprise setup must've already included it).

    Next thing was to Register it with the system using command prompt REGSVR32 THREED32.OCX, successfully registered.

    Back to VB6, Project - Components - Controls tab ... ticked 'Sheridan 3D Controls', clicked OK ... error message "Object Library not registered". Result was that Sheridan would not stay ticked.

    Back to command prompt... REGTLIBV12 MSDATSRC.LIB, successful.

    Restarted VB6, reloaded original .MAK project file, looked at Form... HEY PRESTO... SSOption radio buttons now completely intact! Also checked another form using SSCheck controls, and those too appear as expected. No manual conversion or redevelopment from original VB3 source code

    As expected... Pressing PLAY still gives a Compile error, however i'll move onto that and attempt to debug before bothering you guys further.

    Many thanks for all of your help once again!
    __________________________________________________________________________________________
    MorkenTheMonk
    SCOTLAND

    (Stuck supporting a 16-bit VB3 application over 20 years old! Deep Joy!!!)

  11. #11
    gibra
    Guest

    Re: VB3 to VB6 - Sheridan 3D Controls

    Caution.

    VB6.0/Vs6.0 setup doesn't install the THREED32.OCX by default. This must be installed by hand.
    If you finded the ocx already in your system, then this was installed by setup of other program.

    You should find this, and many others controls, on installation CDs in this folder:
    \Common\Tools\vb\Controls

    Any case, to use this controls on VB6 IDE, you have to register the license using vbctrls.reg (double-click it)
    There are others .reg files to register many controls.

    The README.TXT explain how to.

  12. #12
    PowerPoster
    Join Date
    Feb 2012
    Location
    West Virginia
    Posts
    14,205

    Re: VB3 to VB6 - Sheridan 3D Controls

    Also note that just registering the control isn't enough. You need the developer permissions also. In that same folder where the extra controls for old projects are is a read me and a reg file. Everything you need should be in that folder including the instructions of what to do.

    I do not know what VB6 will do if the project has references to vbx files as I have never tried that, I have VB4 on a VM as well as VB3 and use those to load and convert old projects when the need comes along course has been about 20 years now since I had a need to do that.

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