Results 1 to 33 of 33

Thread: VB3 App on XP [Resolved]

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    VB3 App on XP [Resolved]

    I need to ensure an old VB3 app works on XP. The first thing I noticed is that the text of a msgbox is unreadable as per the attachment.

    What would cause this and how can I fix it (without changing the code)?

    I tried setting the Exe file's "Compatibility Mode" to every possible option but it did not make a difference.
    Attached Images Attached Images  
    Last edited by brucevde; Feb 27th, 2009 at 06:42 PM.

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: VB3 App on XP

    I have no idea if this would have anything to do with anything, but VB3 forms were saved, by default, as binary. Would that cause this behavior I wonder?

  3. #3

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    I doubt very much that that would cause this problem. Fortunately, the forms of this project were saved as text. The program code is simply calling the MsgBox function.

  4. #4
    PowerPoster Code Doc's Avatar
    Join Date
    Mar 2007
    Location
    Omaha, Nebraska
    Posts
    2,354

    Re: VB3 App on XP

    This is really weird, Bruce. I have several of my old VB3 Apps running on my Win XP machine and all the message boxes work fine. I just checked again on this laptop that I'm running while the desktop PC is being repaired. No trouble at all.
    Doctor Ed

  5. #5

  6. #6

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    VB3 App on XP Re:

    The project contains too many files, too many third party VBX files.

    The code that produces the dialog screen above is simply

    If cmbServerName = "" Then
    MsgBox "Must supply a server name"
    Exit Sub
    End if

    Basically, a login form requires you to choose a server from a combobox. The login form displays fine.
    Last edited by brucevde; Feb 27th, 2009 at 06:59 PM.

  7. #7

  8. #8
    PowerPoster Code Doc's Avatar
    Join Date
    Mar 2007
    Location
    Omaha, Nebraska
    Posts
    2,354

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    The project contains too many files, too many third party VBX files.The code that produces the dialog screen above is simply

    If cmbServerName = "" Then
    MsgBox "Must supply a server name"
    Exit Sub
    End if

    Basically, a login form requires you to choose a server from a combobox. The login form displays fine.
    I just replicated this exact code in VB3 and it works on my two Win XP machines. My belief is that the other components "too many files, etc." in the program mean nothing.
    Doctor Ed

  9. #9

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    Well if you attach the exe I'll see what happens if I run it.
    Do you have all the necessary VB3 supporting files? Regardless, this will have to wait until Monday. I zipped the exe and project files and tried to email it to myself so I could work on it this weekend. Unfortunately it appears the email was blocked along the way.

    Now I don't have an excuse to get out of Christmas shopping!!!

  10. #10

  11. #11

  12. #12

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    I don't think this is a VB3 problem at all but a setup issue, specifically Fonts and/or font mapping. All computers in this organization exhibit the same problem and they are all created from the same image (or so I'm told).

    Rhinobull, if you could create a simple VB3 exe and upload it here I would appreciate it. Just a form with a command button that when clicked executes MsgBox "Hello World" will suffice. Thanks.

  13. #13
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    Do you have all the necessary VB3 supporting files?
    I still use VB3 and VB4 16bit. I've converted hundreds of VB3/4 exe's to VB6 and I've never had a problem with messageboxes when converting. It looks like a font problem to me. If you could just post the VB3 exe that would help a lot.

    Here is a VB3 hello MsgBox.
    Attached Files Attached Files
    Last edited by Keithuk; Dec 7th, 2008 at 08:23 AM.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  14. #14

  15. #15
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    @RhinoBull its strange to see you don't use Option Explicit in VB3 apps, bad move. I know this is a simple app but you still need it setting up in Enviroment.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  16. #16

  17. #17
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by RhinoBull
    How is it relevant?
    We try to troubleshoot strange behaviour - not syntax "best practices".
    Common, there are times when you need to say and there are times when you don't.
    Relevant or not this is common practice when using all versions of true VB. As I said it may not matter in a VB3 app with one line of code but surely its good practice to get into this routine.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  18. #18

  19. #19
    PowerPoster Code Doc's Avatar
    Join Date
    Mar 2007
    Location
    Omaha, Nebraska
    Posts
    2,354

    Re: VB3 App on XP

    Quote Originally Posted by RhinoBull
    Let it go Keith, let go.
    Agreed. Option Explicit is not an act of God that is cast in stone.
    Doctor Ed

  20. #20
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by RhinoBull
    Let it go Keith, let go.
    I'll let it go this time only because you helped me with my default printer problem, thanks again.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  21. #21
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: VB3 App on XP

    Keith,

    I agree with you but that's way beyond the point, though...
    you need to understand and stop dragging this thread away from its orginal issue - it is not about best practices what so ever.
    Bruce has a puzzle with displaying ascii characters on xp machine and this is probably more of a General Discussion question.
    Who cares whether there was or was not Option Explicit utilized [in this case]?

    Best regards.

  22. #22

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    Thanks guys for creating/uploading the exe. Both programs displayed the message box just fine.

    Now it looks like this has something to do with the TrueGrid.VBX.

    I deleted all the VBX files that this program uses to the recycle bin and then ran the app. A message box complaining about a missing VBX file displayed just fine. I then restored the VBX files one by one but after restoring the TrueGrid.VBX (3rd one) the message boxes became garbled. The TrueGrid.VBX file is version 2.0.0.7 (TrueGrid® Pro/Std VBX Control).

    If you have TrueGrid I would appreciate another test app with a form that contains this control. It doesn't have to do anything except display a message box. I am still waiting for the brilliant IT department to setup a Virtual Machine using VM Ware so I can actually use/test VB3.

    Incidentally, when you open a VB3 frm file in notepad what is the Version # at the top of the file. All my files have Version 2.00.

  23. #23
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    Incidentally, when you open a VB3 frm file in notepad what is the Version # at the top of the file. All my files have Version 2.00.
    I saved it as binary so can't tell you at the moment - would have to wait untill some later time tonight.

  24. #24
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    Now it looks like this has something to do with the TrueGrid.VBX.

    Incidentally, when you open a VB3 frm file in notepad what is the Version # at the top of the file. All my files have Version 2.00.
    I think I have a VB3 app that uses TrueGrid.vbx but its going to take some finding. I know TrueGrid.vbx can't be used in VB6 but I think I've got around that by using Grid32.ocx.

    There is no version number in any of my VB3 mak files. Come to think of it there is no version number in any VB6 16bit vbp files either.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  25. #25

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    The Version # I am talking about is in the FRM files. You can only see it if you open the file in Notepad (and it wasn't saved as Binary). Here is a sample

    Code:
    VERSION 2.00
    Begin Form frmSupplyMail 
       BorderStyle     =   1  'Fixed Single
       Caption         =   "Scan Mailing Labels"
    A VB6 FRM file contains Version 5.00 so it's probably not a big deal.

  26. #26
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    The Version # I am talking about is in the FRM files. You can only see it if you open the file in Notepad (and it wasn't saved as Binary).

    A VB6 FRM file contains Version 5.00 so it's probably not a big deal
    Sorry I thought you meant the project file. Yes the frm files are VERSION 2.00, VB4 16bit are VERSION 4.00 and VB6 VERSION 5.00.

    Its no big deal if your using VB6.
    Last edited by Keithuk; Dec 8th, 2008 at 06:37 PM.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  27. #27

  28. #28
    Hyperactive Member Max Peck's Avatar
    Join Date
    Oct 2007
    Posts
    384

    Re: VB3 App on XP

    Bruce,

    It looks like a problem with the fonts on your system. The VB3 app might be calling for a font that doesn't exist on your box. That can often be the case when you get garbage where text should be.

    -Max
    The name's "Peck" .... "Max Peck"

    "If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." - Red Adair

  29. #29

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    I thought that at first too and it still may be the cause but right now I think the problem is with a component. As I mentioned earlier, I have found the culprit to be the TrueGrid.VBX. I finally have my pc setup(10 days, escalated to 7 different techs) so I can access the virtual machine where they keep their VB3 projects. Today I hope to create a test app and will post it here.

  30. #30

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    Here is my simple VB3 test app. The form contains an empty TrueGrid, which causes the problem on our computers. If someone can find the time to download the zip file, run the exe and let me know the results that would be great. Thanks.
    Attached Images Attached Images  
    Attached Files Attached Files

  31. #31
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Well I can't get it to recognize the Truegrid.vbx. I don't have the licence to use it in Design Mode.

    I shall have to do a search for that app that I have that uses Truegrid.vbx, I'm sure I've seen the name before.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

  32. #32

    Thread Starter
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: VB3 App on XP

    Don't bother. I managed to find and download a different version of this VBX off the net which solves the problem.

  33. #33
    PowerPoster Keithuk's Avatar
    Join Date
    Jan 2004
    Location
    Staffordshire, England
    Posts
    2,236

    Re: VB3 App on XP

    Quote Originally Posted by brucevde
    I managed to find and download a different version of this VBX off the net which solves the problem.
    Do you have a link to this vbx download Bruce? I've downloaded a few but the license is still the problem.

    I remember one app that uses Truegrid.vbx its Truck Game. I decompiled this app many years ago and I get same error, don't have a license to use in Design Mode.

    I've seen many questions asking about this license on the web. I believe they have changed TRUEGRID to TDBG16 Visual Basic 3 to 4 Conversion.

    Now the beauty of vbx files is they don't have to be in the Win\Sys folder. I put Truegrid.vbx in my Win\Sys folder but that makes no difference.
    Keith

    I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.

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