Error 321, Invalid File Format (vb4, 16 bit) 
Author Message
 Error 321, Invalid File Format (vb4, 16 bit)

This has me really stumped.

The program runs fine in design mode.  Crashes with the exe.  It appears to
be happening around some GetPrivateProfileString calls... (I could be wrong
though)

Funny thing is, I compiled an exe that was installed on a client machine
last week and everything ran fine.  This week the problem started
occurring.  I have only added one new form to the project, but I have not
changed the database or the ini file at all.

Any help would be greatly appreciated.

--
Please post response to newsgroup, or ayoakumATlandrumDASHbrownDOTcom
Thank you!
A. Yoakum



Sat, 08 Jul 2000 03:00:00 GMT  
 Error 321, Invalid File Format (vb4, 16 bit)

For what it is worth I did an inquiry during design mode (pause, immediate
window, "error 321") and received the following message:

Run-time error
Invalid file format

I'm running VB5.0, SP3, Win95

Eric

--
==========================================
My reply e-mail address is intentionally wrong.
Remove the characters nospam_, or use the address

==========================================



Sat, 08 Jul 2000 03:00:00 GMT  
 Error 321, Invalid File Format (vb4, 16 bit)

This kind of problem is often causes by a related dll to one of the control
you use.

Make sure that all the dll used by the controls are up to date on all
client machines.
Then, make sure that this ocx is properly register with regsvr.

It would also be helpful to know when you get this error...put some
messagebox to see if it is during the form load.
If it`s in the form load, it is sure that the cause is a control.  You
would then have to delete the oca file of the ocx and redo the reference to
this control in vb in order to create
the proper oca.  Then, make sure that this ocx is properly register with
regsvr.



Quote:
> This has me really stumped.

> The program runs fine in design mode.  Crashes with the exe.  It appears
to
> be happening around some GetPrivateProfileString calls... (I could be
wrong
> though)

> Funny thing is, I compiled an exe that was installed on a client machine
> last week and everything ran fine.  This week the problem started
> occurring.  I have only added one new form to the project, but I have not
> changed the database or the ini file at all.

> Any help would be greatly appreciated.

> --
> Please post response to newsgroup, or ayoakumATlandrumDASHbrownDOTcom
> Thank you!
> A. Yoakum



Sun, 09 Jul 2000 03:00:00 GMT  
 Error 321, Invalid File Format (vb4, 16 bit)

It could be the platform your running the GetPrivateProfileSting calls from,
maybe.

There is a difference in declarations of the API between the 16 bit and
Win95.  Therefore, if you run your 16 bit app on a 95 box, then the
declaration is syntactically incorrect to import the win32 version.

If'n this is the case, then you'd just need to add declarations for both in
conditional compile branches in the general declarations section like this.
. .

#If Win32 Then
    'paste win32 API import declarations here
#Else
    'paste 16 bit version here
#End If

:) smiles


Quote:
>This has me really stumped.

>The program runs fine in design mode.  Crashes with the exe.  It appears to
>be happening around some GetPrivateProfileString calls... (I could be wrong
>though)

>Funny thing is, I compiled an exe that was installed on a client machine
>last week and everything ran fine.  This week the problem started
>occurring.  I have only added one new form to the project, but I have not
>changed the database or the ini file at all.

>Any help would be greatly appreciated.

>--
>Please post response to newsgroup, or ayoakumATlandrumDASHbrownDOTcom
>Thank you!
>A. Yoakum



Mon, 10 Jul 2000 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Error 321, Invalid File Format (vb4, 16 bit)

2. Error 321, Invalid File Format (vb4, 16 bit)

3. Error 321, Invalid File Format (vb4, 16 bit)

4. Error "321" -- Invalid File Format

5. Runtime error '321' Invalid file format

6. HELP: VB4.0 16-bit upgrade invalid

7. 16-bit VB4 causes invalid page fault in Win95

8. 16-bit VB4 causes invalid page fault in Win95

9. Calling 16 bit DLL from VB4 16 bit in Win 95

10. Russian(Cyrillic): vb4 32-bit works, but vb4 16-bit doesn't

11. VB5, SP3, and Error 321 "Invalid File format" accessing Books Online.

12. Q: I am getting a 321 runtime error "Invalid File Format" HELP?

 

 
Powered by phpBB® Forum Software