logo elektroda
logo elektroda
X
logo elektroda

Excel Runtime Error 1004: MVB Issue with Data Collection Files in Microsoft Office 2007

luks212 15771 12
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 15595200
    luks212
    Level 8  
    Hello,

    I have a problem. I say right away that I am not very proficient in the technical side of excel.

    So:
    I have such a tool for work: http://art30a.ucoz.pl/news/narzedzia_analiza2016_udostepniane/2016-03-14-49

    When I try to generate 'data collection files' I get the error:
    "Microsoft Visual Basic. Run-time error '1004'. Method 'Open' of object 'Workbooks' failed."

    99% of it is a problem with the computer / software of the computer, as the tool works fine on all other computers.
    Normally, I would make a computer format and re-load whatever it takes, but there are very important data and programs there and the person using the computer does not agree to this.

    The specification of the computer is:
    WIN7 64bit, 4GB RAM, i5 3.20GHz processor (I don't remember the exact model).
    Currently Microsoft Office 2007 Smallbussiness is preloaded, but I tried on Office 2007 Professional as well. Both have the same symptom.

    The computer was scanned by ESET antivirus and no viruses were detected.

    Most likely, my next step will be to install Office 2013, but I would also like to get advice on fixing this bug on the 2007 version.


    Thank you for your help and best regards.
  • ADVERTISEMENT
  • #2 15597789
    marcinj12
    Level 40  
    Have you tried to run this tool with no data (or only basic data) taken straight from this link, what did you enter?
    Do you run them with other files closed?
  • ADVERTISEMENT
  • #3 15599842
    luks212
    Level 8  
    Yes, of course I tried.
    I also tried on a new account with administrator rights - still the same; /
    It works fine on the 2013 version, but I would have to purchase an additional license.
  • #4 15600141
    marcinj12
    Level 40  
    As I understand it, the error shows up, but does not enter the VBA editor, does not highlight any line?
    Check the regional settings if the same languages are set on both computers. In particular, in Region and Language-> Administrative-> Language for non-Unicode programs.
    If they are the same, I would try reinstalling Office 2007.
  • #5 15600220
    luks212
    Level 8  
    Yes, only the message: "Microsoft Visual Basic. Run-time error '1004'. Method 'Open' of object 'Workbooks' failed."

    And I have a choice: "End" and "Help".

    I have already reinstalled Office, even before reinstalling it, I cleaned its remains with the EasyFix program from Microsoft.

    Reinstalling also did not help. ; /
  • ADVERTISEMENT
  • #6 15600666
    marcinj12
    Level 40  
    On the Files tab, cell C4 has a path. What value does the function return there? How long is its name, does not exceed 220-230 characters? This looks like the correct path that exists? Make sure you don't end with a \.

    Test copy the entire directory (and preferably use a fresh, blank copy from the page) to some short location, eg C: \ test. Grant Users full permissions on this directory and check it then.
  • ADVERTISEMENT
  • #7 15602085
    luks212
    Level 8  
    The path is perfectly correct.

    The error keeps popping up. : / I don't have any clue what's going on anymore.
  • #8 15602751
    marcinj12
    Level 40  
    Well, I'm afraid it's hard to tell from a distance. There can be dozens of causes for this problem. Further asking is pointless.
  • #9 15608503
    Prot
    Level 38  
    You don't write about it, so I'll ask: have you ever worked with this "tool" on this computer? Is the ability to work with macros sheets unlocked? did the author of this sheet define any special requirements, e.g. references for VBA?

    I had a similar effect - error 1004 - with a defective VBA script, which I was looking for some string patterns in the database, and which were less in a given field than in other fields :D
  • #10 15614031
    luks212
    Level 8  
    There was no problem with the 2015 version and with the older ones. The macros are unlocked of course.
    In general, there is probably a bigger problem with it, because the author has already released the third amendment to this version.

    He also recommended enabling some additional components in MS Visual Basic, but I can't do that because I just don't have this references dialog active in the Tools tab.
  • #11 15614983
    Prot
    Level 38  
    My feel is there are indeed some errors in the script causing your "1004" message.
    This grayed out IMHO references button indicates that the script was stopped because of an error, not terminated :D . Then try to click Run, let it go to the end and only then you will be able to complete the setting of appropriate references for this script. The absence of these references can also cause "Run time error".
  • #12 17183138
    dzikzlasu
    Level 2  
    I know the old topic, but I've just figured out what's going on, because I have a similar problem,
    It's not about the name of the file! and the number of characters in the name
    change the name to one letter, e.g. A
    if it works, you already have an answer, if it still doesn't work, see the path!
    for me, the path with the filename took more than 250 characters.
    after changing the path to E: \ test \ the macro has started
  • #13 17970393
    wimich
    Level 12  
    Hello,
    maybe it will be useful to someone. I had a similar problem, except that the macro opened dozens of files for me in a loop. Everything worked for over a year and a half, and then suddenly about a week ago it started to stop at the open method, but not at the first but at the second pass through the loop. Interestingly, it was enough to let go of the macro and it went to the next position of the loop without any problems and it stopped again. And so on through all files. In the end, everything was going, but it was terribly troublesome because the macro was restarted several dozen times after stopping. The solution was to set the open Local: = True.

Topic summary

The discussion revolves around a "Run-time error '1004'" encountered while using a data collection tool in Microsoft Office 2007. The user reports that the tool functions correctly on other computers but fails on their system, which runs Windows 7 64-bit with 4GB RAM and an i5 processor. Various troubleshooting steps are suggested, including checking file paths, ensuring macro settings are enabled, and verifying regional settings. The user has attempted to reinstall Office 2007 and run the tool with minimal data, but the error persists. Other users suggest potential issues with the VBA script and file path length, recommending testing with shorter paths and names. A workaround involving setting the open method to Local: = True is also mentioned.
Summary generated by the language model.
ADVERTISEMENT