Results 1 to 29 of 29

Thread: VB Issue - Finally Resolved :: Thanx All :D

  1. #1

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718

    VB Issue - Finally Resolved :: Thanx All :D

    I have recently recovered from a virus, and have had to re-install VB 6.0 Ent. A program which used to function.. now doesn't! HELP!

    Here is the offending code:

    Code:
    allfields = string(LOF(1), Chr$(0))
    When the package runs... it says

    "Can't find project or library" with Chr$ highlighted!

    Any idea's?

    Regards,

    Paul.
    Last edited by VisionIT; Jan 19th, 2003 at 05:10 PM.

  2. #2
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    well the file that contains that function is

    C:\WINNT\System32\MSVBVM60.DLL

    also.. did you install service pack 5 when you reinstalled?

  3. #3

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718

    Haven't installed SP yet...

    The MSVBVM60.DLL file is located in sys32 directory, but it still refuses to work! Arrgghhh

    Regards,

    Paul.

  4. #4

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Just another quick note:

    I have removed the line, and it then says the same message for:

    Code:
    For i = 1 to 20
    This has to be a component/reference thing, but which one should i enable?

    Regards,

    Paul.

  5. #5

  6. #6

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    The system was flattened prior to a re-install. No OS, nothing!

    Can't understand it... HELP. Surely there's just an option i haven't clicked?

    Regards,

    Paul.

  7. #7
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    1) did you reformat the drive?
    2) did you install SP5 after the VB install?

  8. #8
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,431
    Originally posted by VisionIT
    The system was flattened prior to a re-install. No OS, nothing!

    Can't understand it... HELP. Surely there's just an option i haven't clicked?

    Regards,

    Paul.
    Where did you get your code from? If it was from some sort of external backup which also contained your vbp file, that file should know all about the components and references you need.

  9. #9
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373
    Originally posted by MartinLiss
    Where did you get your code from? If it was from some sort of external backup which also contained your vbp file, that file should know all about the components and references you need.
    yeah or start a new app and see if you can run it...

  10. #10
    Addicted Member
    Join Date
    Jul 2002
    Posts
    234
    You might also just step through your code to make sure everything is correct. On occasion, I receive this type of error for the MID command, but it generally occurs as a result of nesting or a syntax error somewhere earlier in the program.

  11. #11

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Originally posted by MartinLiss
    Where did you get your code from? If it was from some sort of external backup which also contained your vbp file, that file should know all about the components and references you need.
    Mr Genius... i bow to thee !

    It's fine now... i just opened the VBP file in wordpad, and read all the keys !

    Nice one!

    Regards,

    Paul.

  12. #12
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,431
    I'm happy my suggestion helped, but you actually misinterpreted what I meant. What I was trying to say was that the vbp file should know about the components and references you need and choose/select them automatically. I wonder why it didn't do that and you were (I assume) forced to reselect them?

  13. #13
    Fanatic Member Armbruster's Avatar
    Join Date
    Sep 2002
    Location
    Maryland Heights, MO
    Posts
    857
    Marty,

    My best guess is he created a project and then later tried to open just one form, not the project. In this case it would create a new .vbp file with the generic references. Now the big question becomes, why was the generic .vbp file missing vb references library? Or was he just opening it with a corrupt .vbp file? Anyway, I've seen similar problems to this issue, so that would be my guess
    "Look! Up in the sky! It's a bird! It's a plane! It's Diaper-Head Boy! (there by my name!) Yes, Diaper-Head Boy, who disguised as my son, Seth, fights a never-ending battle for truth, justice and terrorizing my house!

    Resistance is futile, you will be compiled . . . Please!

  14. #14

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Armbuster...

    Just to let you know, I was opening the package and not just a form, but STILL NOW... it refuses to work!

    I'm in the process of formatting the system (again), so i'll see what it errors with then.

    I thought i'de done it yesterday... turns out, it's still crashing with the same message.

    Can anyone advise?

    Regards,

    Paul.

    P.S No service pack yet!

  15. #15
    Fanatic Member Armbruster's Avatar
    Join Date
    Sep 2002
    Location
    Maryland Heights, MO
    Posts
    857
    VisionIT,

    These are the default references assigned when you create a new standard exe project. Does your project have these references?

    Attached Images Attached Images  
    "Look! Up in the sky! It's a bird! It's a plane! It's Diaper-Head Boy! (there by my name!) Yes, Diaper-Head Boy, who disguised as my son, Seth, fights a never-ending battle for truth, justice and terrorizing my house!

    Resistance is futile, you will be compiled . . . Please!

  16. #16

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Yep... all those are listed. Can't understand why it's happening? It's 23Mb, and i'm NOT re-typing it! LOL

    Regards,

    Paul.

  17. #17
    Fanatic Member Armbruster's Avatar
    Join Date
    Sep 2002
    Location
    Maryland Heights, MO
    Posts
    857
    Please tell me your .vbp file isn't 23 Meg!! If it is, then it is definately corrupt. It should be about 2-3 KB, maybe 5-6 KB, but definately nowhere near a meg. It would be easy to recreate. Simply open one of your forms. This would open a default project. Add the rest of your forms and modules and any missing references and your done. It really would be quite easy.
    "Look! Up in the sky! It's a bird! It's a plane! It's Diaper-Head Boy! (there by my name!) Yes, Diaper-Head Boy, who disguised as my son, Seth, fights a never-ending battle for truth, justice and terrorizing my house!

    Resistance is futile, you will be compiled . . . Please!

  18. #18
    Frenzied Member McGenius's Avatar
    Join Date
    Jan 2003
    Posts
    1,199
    Originally posted by kleinma
    1) did you reformat the drive?
    2) did you install SP5 after the VB install?
    SP isn't necessary - core functions libarry will be present regardles off any fixes.

    What I would try to do is to open a brand new project and try using any of "built-in" finctions and keywwords (especially String functions because most of them are part of VBA labrary). If that works then add all of your forms and modules to that project and get rid of default Form1. This should work. These sort of things are happening from time to time - your System has lost a pointer to one of VB's core library for some particular project, but when you start a brand new one - it will "refresh" itself.

    Hope this will help you.
    McGenius

  19. #19

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718

    Sorry...

    My mistake...

    the whole package is 23mb's, not the VBP file.

    I've tried creating a new program, and it still crashes with that !

    I'm flattening the system now... so i'll BRB

    Regards,

    Paul.

  20. #20
    Fanatic Member Illspirit's Avatar
    Join Date
    Mar 2001
    Location
    Blackpool, England
    Posts
    815
    hey,

    i have the exact same problem with my project. I created it under windows xp, and then tried running it under 98. It didnt load, and i couldnt figure out why, so i installed VB on the 98 machine and ran my project through the interperator, and it highlights almost every line of basic stuff.

    I found that adding VBA. before lines like Mid$, Chr$, Format, Instr, Left, etc made them work, but functions line Input still dont work and i cant add VBA. before them

    VB Code:
    1. MsgBox Left$("blah blah", 4) 'Doesnt work
    2.    
    3.     MsgBox VBA.Left$("blah blah", 4) 'Works

    Does this work for u? or do i have a different problem?
    Illspirit - [email protected]

    SmartBarXP Lead Developer
    SmartBarXP - The leading desktop sidebar application for Microsoft Windows XP

  21. #21

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718

    Oh... too l8

    Sorry, but i've already started the format. It should be ready in a few hours. There's 3 x 200Gb's to format BTW, thats why it takes sooooo long!

    If the problem still occurs after the format (hope it doesn't), i'll try it and let you know.

    Hope you get your's fixed !

    Regards,

    Paul.

  22. #22
    Frenzied Member Blobby's Avatar
    Join Date
    Oct 2001
    Location
    England
    Posts
    1,512
    So far at least 2 people have asked if you have installed Service Pack 5 and you still havent answered them.


    Can u post ur project and we'll see if we can run it?
    There are 3 types of people in this world.........those that can count, and those that can't.

    Blobby

  23. #23

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Er... i think you'll find i have Look at my reply to Armbuster!

    This package can not be given to an external source for security purposes, sorry. It's not my decision.

    Regards,

    Paul.

  24. #24
    Frenzied Member Blobby's Avatar
    Join Date
    Oct 2001
    Location
    England
    Posts
    1,512
    hehehe OK my apologies, ill let you off then! but the reply was 'no service pack yet'. Whats all that about? You having trouble downloading it?

    Have you tried opening and running other large vb apps to see if its just a prob with that particular program?
    There are 3 types of people in this world.........those that can count, and those that can't.

    Blobby

  25. #25
    Frenzied Member Blobby's Avatar
    Join Date
    Oct 2001
    Location
    England
    Posts
    1,512
    .....and you dont have to format the other 2 drives as they arent needed to get windows and vb up and running, you can do them later
    There are 3 types of people in this world.........those that can count, and those that can't.

    Blobby

  26. #26

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    No problems with downloading the SP, i just haven't got round to it

    Our format function format's all the drives on the IDE / MB133 at the same time, so windows registers the RAID for the other 2 200Gb's drives.

    Anyway... the system has just finished... so i'll BRB.

    Regards,

    Paul.

  27. #27

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    Well... it's finally finished installing... and you'll never guess !

    It still DIDN'T WORK... but now it's fine.

    SOLUTION:

    Uncheck EVER reference & component, and save. Re-open and apply all the previous references & components.. and it's done !

    Oh... and the VBA. prior to the code worked perfectly BTW, but I decided to find the root of the problem.

    Thankyou all for the help, but I must finish it now.

    Kind Regards,

    Paul.

  28. #28
    Fanatic Member Illspirit's Avatar
    Join Date
    Mar 2001
    Location
    Blackpool, England
    Posts
    815
    aha, i'll give that a whirl too then when i have a few hours spare to let my 98 box boot up

    If it works i owe u 1 m8
    Illspirit - [email protected]

    SmartBarXP Lead Developer
    SmartBarXP - The leading desktop sidebar application for Microsoft Windows XP

  29. #29

    Thread Starter
    Fanatic Member VisionIT's Avatar
    Join Date
    Nov 2002
    Location
    Workin'...
    Posts
    718
    If it works... i'll bill you! LOL



    Program works a treat now... as it did before the format a few weeks ago! So glad it works... or i'de have lost a contract.

    Regards,

    Paul.

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