• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1020
  • Last Modified:

Forms Loading As Modules

Hi,

  I have a VB6 project and am trying to load it onto another computer with VB6.  However, it says "error during load" and the log says that the forms aren't being loaded (the forms are physically located in the same directory as the project file, along with their associated *.frx files).  When I try to manually add these forms, they show up as modules!

  Any ideas?

Thank you,
TK
0
tkeeler1
Asked:
tkeeler1
4 Solutions
 
hesCommented:
Is the version of VB6 the same on both machines(Pro vs Enterprise)
Is the Service Pack level the same (sp1-sp6)
0
 
tkeeler1Author Commented:
I'm not sure.  I don't have the original computer anymore.  If not, is there a work-around for this problem?

Thanks,
TK
0
 
Dany BalianCTOCommented:
when the form fails to load... usually it creates a log file in the same folder with the same name as the form

check it... maybe the form is referencing an ocx or dll that doesnt exist anymore

hope this helps...

dan
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
tkeeler1Author Commented:
The error log just says that the form failed to load!  :(  No help....

Is there anything you know of that's different in the headers of different VB6 versions, that would make this problem happen?

Thanks,
TK
0
 
jkaiosIT DirectorCommented:
In addition to what mrdanny suggested, which seemed to the closer/correct answer is that you have to check your project file, too.
The project file is the one that ends with .vbp and check if your project contains references to any OCX or ActiveX DLL.

References to OCXs are stored in the .VBP file with lines starting with "Object="
References to DLLs are stored in the .VBP file with lines starting with "Reference="

You probably might have referenced one of these OCXs or DLLs in your project that do not exist on the other machine.
0
 
tkeeler1Author Commented:
Hi,

  Even forms without any DLLs or OCX's needed (like the "About" screen) didn't load.  I know what you mean though-- I've tried loading it without the DLLs in the past, and gotten a different error (like couldn't find library).  This one's just different--  no forms load no matter what.

Any other ideas?

Thanks,
TK
0
 
Dany BalianCTOCommented:
do u think u can upload the vbp file and maybe one form (the "about form") to eestuff.com? so that we'll take a look??

cheers,

dan
0
 
tkeeler1Author Commented:
Hi Dan,

  How do you upload files to EEstuff.com?

Thanks,
TK
0
 
tkeeler1Author Commented:
Hi Dan,

  I figure that it might be easier to post the code here.  The error I'm getting in the FrmAbout.log is the following:

'0' could not be loaded
Line 0: The file C:\Documents and Settings\user\Desktop\frmAbout.frm could not be loaded.

Here's the VBP code (note that there are some references to OCX's that won't load-- but the main problem is that the form isn't loading):
----------------------------------------------
Type=Exe
Reference=*\G{00020430-0000-0000-C000-000000000046}#2.0#0#..\..\..\..\WINDOWS\system32\stdole2.tlb#OLE Automation
Reference=*\G{D1BA5044-2242-11D2-9F5A-00A0C9879443}#1.0#0#..\..\..\..\Program Files\ARAT\EWOSS 2000\SaxComm6.ocx#Sax Comm Objects 6.0
Object={D1BA5044-2242-11D2-9F5A-00A0C9879443}#1.0#0; SaxComm6.ocx
Reference=*\G{DB797681-40E0-11D2-9BD5-0060082AE372}#5.0#0#..\..\..\..\WINDOWS\SYSTEM32\XceedZip.dll#Xceed Zip Compression Library v5.1
Reference=*\G{91493440-5A91-11CF-8700-00AA0060263B}#2.6#0#..\..\..\..\Program Files\Microsoft Office\OFFICE11\msppt.olb#Microsoft PowerPoint 9.0 Object Library
Reference=*\G{293364AC-43F8-11D3-BC2D-4000000A2806}#2.0#0#..\..\..\..\WINDOWS\SYSTEM32\cgziplibrary.dll#CodeGuru Zip Library
Reference=*\G{420B2830-E718-11CF-893D-00A0C9054228}#1.0#0#..\..\..\..\WINDOWS\system32\scrrun.dll#Microsoft Scripting Runtime
Object={3B7C8863-D78F-101B-B9B5-04021C009402}#1.2#0; RICHTX32.OCX
Object={F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0; COMDLG32.OCX
Object={BDC217C8-ED16-11CD-956C-0000C04E4C0A}#1.1#0; TABCTL32.OCX
Object={831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0; MSCOMCTL.OCX
Object={86CF1D34-0C5F-11D2-A9FC-0000F8754DA1}#2.0#0; MSCOMCT2.OCX
Object={38911DA0-E448-11D0-84A3-00DD01104159}#1.1#0; COMCT332.OCX
Object={648A5603-2C6E-101B-82B6-000000000014}#1.1#0; MSCOMM32.OCX
Form=frmAbout.frm
Module=Settings; Settings.bas
Module=Registry; Registry.bas
Module=SendBinaryMDS; Binary.bas
Module=CMWS; CMWS.bas
IconForm="MainForm"
Startup="MainForm"
HelpFile=""
Title="ARATSSL"
ExeName32="ARATSSL.exe"
Command32=""
Name="EEARATSSL"
HelpContextID="0"
CompatibleMode="0"
MajorVer=2
MinorVer=0
RevisionVer=0
AutoIncrementVer=0
ServerSupportFiles=0
VersionCompanyName="SRI International"
CompilationType=0
OptimizationType=2
FavorPentiumPro(tm)=0
CodeViewDebugInfo=0
NoAliasing=0
BoundsCheck=0
OverflowCheck=0
FlPointCheck=0
FDIVCheck=0
UnroundedFP=0
StartMode=0
Unattended=0
Retained=0
ThreadPerObject=0
MaxNumberOfThreads=1
DebugStartupOption=0

[RVB]
DeleteClass1=MDIForm1
DeleteClass2=Form1
DeleteClass3=frmSplash

[MS Transaction Server]
AutoRefresh=1

---------------------------------------

FrmAbout Code:

VERSION 5.00
Begin VB.Form frmAbout
   BorderStyle     =   3  'Fixed Dialog
   Caption         =   "About Goodies"
   ClientHeight    =   5985
   ClientLeft      =   2340
   ClientTop       =   1935
   ClientWidth     =   9675
   ClipControls    =   0   'False
   Icon            =   "frmAbout.frx":0000
   LinkTopic       =   "Form2"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   299.25
   ScaleMode       =   2  'Point
   ScaleWidth      =   483.75
   ShowInTaskbar   =   0   'False
   StartUpPosition =   1  'CenterOwner
   Begin VB.PictureBox Picture1
      AutoRedraw      =   -1  'True
      AutoSize        =   -1  'True
      Height          =   3510
      Left            =   2280
      Picture         =   "frmAbout.frx":0442
      ScaleHeight     =   3450
      ScaleWidth      =   3450
      TabIndex        =   17
      Top             =   360
      Width           =   3510
   End
   Begin VB.CommandButton cmdOK
      Cancel          =   -1  'True
      Caption         =   "OK"
      Default         =   -1  'True
      Height          =   345
      Left            =   7560
      TabIndex        =   0
      Top             =   5400
      Width           =   1260
   End
   Begin VB.Label ClassEmail
      Caption         =   "Goodies@arat.army.smil.mil"
      BeginProperty Font
         Name            =   "MS Sans Serif"
         Size            =   8.25
         Charset         =   0
         Weight          =   400
         Underline       =   -1  'True
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      ForeColor       =   &H00FF0000&
      Height          =   240
      Left            =   1800
      TabIndex        =   16
      Top             =   5640
      Width           =   4605
   End
   End
Attribute VB_Name = "frmAbout"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False

--------------------------------------------
Thanks for your help!
TK
0
 
Dany BalianCTOCommented:
well i copied and pasted ur code into a project1.vbp and frmabout.frm

and i got the same errors, when i double click on the form in designview

the problem is because i dont have ur frx files which contains the pictures of the document...
so i removed the lines that reference the frx files...
(the form icon line and the picturebox picture line)

and the project and form loaded normally... (except ofcourse for the ocx errors)

so i guess there's sthg wrong in the frx files...
if u remove them.. ur project will load... without pictures...

so remove the frx lines from the forms that give u error only...

is that a good solution???

waiting for ur feedback...

cheers,

dan

0
 
tkeeler1Author Commented:
Hmm... this doesn't solve the problem of why the frx files worked on my old computer, and not this one... ?

I have several forms in this project that won't load, so I'm hesitant to redo all of them, if there's a better fix.  Is there any wayt to determine if there's a line or some syntax error that would make everything work?

Thanks,
TK
0
 
ArkCommented:
Not sure, but did you try change relative path like
..\..\..\..\WINDOWS\system32\stdole2.tlb
to absolute
C:\WINDOWS\system32\stdole2.tlb
0
 
tkeeler1Author Commented:
Okay, I don't think I'm getting anywhere... it's just so strange that versions of VB6 can be so different that a project file won't open!  If anyone comes up with a solution for this, let me know.....

thanks,
TK
0
 
mnoonan080700Commented:
I know this has been closed for a while but I stumbled upon this when searching for a resolution to the same problem (and it doesn't seem like there was really a solution given here).  What I found was that my source control application (Clearcase) had a text mode setting set wrong so that my form files where not formatted correctly (no carriage returns or line feeds).  Once I corrected that all was well again.
0

Featured Post

Become an Android App Developer

Ready to kick start your career in 2018? Learn how to build an Android app in January’s Course of the Month and open the door to new opportunities.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now