none
MS Access 2007 Application work on Windows XP but not on Windows 7 Ultimate 64 bit RRS feed

  • Question

  • I have application which build in MS Access 2007 and work fine on Windows XP SP3 .When I try to run this application on Windows 7 Ultimate 64 bit then in macro code it produce erro about 'Memory not enough'. So,what's the problem ?
    Tuesday, November 22, 2011 5:01 PM

All replies

  • Can you explain what Macro is running, what action are peformed?

     


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Wednesday, November 23, 2011 7:26 AM
    Moderator
  • Sure... Dani,

    Here is it..

    I am using this application on my desktop which configured :

            Windows XP SP3 ,MS Office 2007, 2 GB RAM and this is working fine with out problem.

    But when I try to run this application on my Laptop which configured :

           Windows 7 64 bit,MS Office 2007,3 GB RAM It show me error on startup.

     

    => ERROR DESCRIPTION

          Run-time error '2004':

          There isn't enough memory to perform this operation.Close unneeded programs and try the operation again.

         In Action Failed error box detain

        > Macro Name : AutoExec

        > Condition : True:[CurrentProject].[IsTrusted]=True

        > Action Name : RunCode

        > Agruments : runMain() > Error Number : 2950

     

    I have lots of application loaded on my laptop and it is consuming  averagely 1.94 GB RAM but thenever I have 1 GB free to run any operation.

    when I start this application my ram  In Use 2095 MB (2.6GB)  thenever I have 868 MB standby  and 17 MB free.

    here my cached size is 891 MB and I have available 893 MB.

     

    The macro performing Initialization in Main procedure which call during startup through AutoExec macro.

     

    ***********************************************************************************

    Public Sub initializeProject()

     
    --> Set Objects(ProjectIndex) = New MainObject      'Error Line
    With Objects(ProjectIndex)
            .setObjectName "Project"
            .setTableName ProjectTableName
            .setMainObjectIndex ProjectIndex
            .setIDColumn "ID"

            .setPublishedColumn "Name"
            .setColumnNamesSize 4
      
            .setColumnNamesValue 0, "Des", "Description:"
            .setColumnNamesValue 1, "FNm", "First Name:"
            .setColumnNamesValue 2, "LNm", "Last Name:"
            .setColumnNamesValue 3, "Nm", "Number:"
            .setColumnNamesValue 4, "Dt", "Date:"
         
    End With
    End Sub


    *****************************************************************************************

    Here Objects is

         'OBJECT ARRAY VARIABLES:
         'Array of Main Objects, (see MainObject Class for detailed description), can be accessed from anywhere in Project
         ' Each Index within the array refers directly to a type of Main Object 

          Public Objects() As MainObject

     

    Here MainObject is

         'TYPE: CLASS
         'NAME: MainObject
         'Purpose: Class Inherited from the logical-only class "Table". Any primary table within the application.
                        that exists as relevant records with columns and has relationships with with other primary objects.
                        The code contains properties of the Access table and indexes references for the Sub- and SuperOjects of the MainObject,
                        a FormGroup Object and contains/generates lists of data that are displayed on each type of form. It contains get and set
                       methods for each property as well as intermediary calls between the rest of the project and FormGroup methods.

    Here ProjectIndex is

            'TYPE: Enum
            'NAME: ICMainObjectIndex
            'Parameters: None
            'Purpose: index for the main objets


            Enum ICMainObjectIndex
                  SubIndex = 0
                  ModelIndex = 1
                  baseIndex = 2
                  ProjectIndex = 3
                  VisioIndex = 4
                  capIndex = 5 
           End Enum

    The important thing is I am using here in application Visio,Excel,Word references to get on call.

    I cann't understand how to solve this....please guid me in proper direction.....

    Thanking u in advance.

     

    Wednesday, November 23, 2011 4:24 PM
  • Well, it might be better to add at least another 1 GB of ram, if you are reaching the limits of your internal Memory.

    It might be that Windows 7 needs more resources then Windows XP did.

     

    You might try a Compact & Repair as well, see if that make any difference, but I suspect not much.

     

    Also check this simular thread:

    http://social.msdn.microsoft.com/Forums/en-US/accessdev/thread/704ee431-ec49-482b-875e-0c0a73a4f6b4

     

     

     


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Wednesday, November 23, 2011 5:34 PM
    Moderator
  • Hi Dani...

    According to your suggetion I add 1 GB RAM run application.

    But still same problem....I think It's not about memory....Because of creating so many classe objects runtime thats the problem ?

     

     


    • Edited by Ichchu Wednesday, November 23, 2011 11:17 PM
    Wednesday, November 23, 2011 10:34 PM
  • Did you tried to monitor the Task Manager and see what happen?

    Did you tried the Compact & Repair?

     

    If memory is not the problem, compact & repair did not help, you might be suffering corruption, which isn't nice, but you might be able to resolve.

    See for more info this site:

    http://www.granite.ab.ca/access/corruptmdbs.htm

    http://allenbrowne.com/ser-47.html


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Wednesday, November 23, 2011 11:26 PM
    Moderator
  • Hi Dani...

    your links are quit helpful...I create new database and import all objects and remove all corruption througout compile code.

    but this time it give me error on same code line...but new defination of error...

     

    Run-time error '2950':

    Reserved Error

     

    I cann't understand...

    I notice one thing here in my main procedure if i block  here initializeDatabase procedure then error will go on initializeVisio

    not on initializeProject why?

    public sub runmain()

        initializeSubject
        initializeModel
        initializeDatabase
        => initializeProject     'Error procedure described as above
        initializeVisio
        initializeCapability
    end sub

    if i create object so need to close and free memory ?

     

    • Edited by Ichchu Thursday, November 24, 2011 6:02 AM
    Thursday, November 24, 2011 5:33 AM
  • Can it be that your database is not added to a trusted location?

     

    See below thread:

    http://support.microsoft.com/kb/931407

     

    Hope this helps,


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Thursday, November 24, 2011 6:11 AM
    Moderator
  • I added my Access Datbase 2007 on Trusted Location per ur link guid.

    But Error continue on same line

    but this time the error message change

     

    Run-time error '7895':

    Microsoft Office Access was unable to create window.

     

     

    Thursday, November 24, 2011 5:07 PM
  • I noice one more thing in windows 7 when i m trying to open this application my CPU process 100% ane error occured.Why?

     

    Thursday, November 24, 2011 6:53 PM
  • It's problably crashing for some reason. Somehow your code causing Access to crash, can't fingerpoint why.

     

    Did you tried a Decompile and then a Compile to see if that works?

    http://www.fmsinc.com/microsoftaccess/performance/decompile.asp

     

    Also you might check if you have all the necessary Library's ticked, if one's missing that can cause unaspected errors as well.

     

     


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Thursday, November 24, 2011 7:43 PM
    Moderator
  • Dani....I create new database import all object successfully.

    I compiled and remove all error in minimal references.

    But this application not allow me to RUN,COMPACT OR REPAIR,DECOMPILE....

    all the time same error......

     

    Thursday, November 24, 2011 11:10 PM
  • Another thing when I run MSACCESS.EXE run as administration and

    open my application the erroe description change...

     

    Run-time error '7895' :

    Microsoft Office Access unable to create a window.

     

    and I cann't get this defination on web.why?

     

    Thursday, November 24, 2011 11:53 PM
  • Other thing

    why i m not allow to create object more than 8.....runtime error 2004 ....not enough memory why?

     

        Set Objects(0) = New MainObject
        Set Objects(1) = New MainObject
        Set Objects(2) = New MainObject
        Set Objects(3) = New MainObject
        Set Objects(4) = New MainObject
        Set Objects(5) = New MainObject
        Set Objects(6) = New MainObject
        Set Objects(7) = New MainObject


        Set Objects(8) = New MainObject
        Set Objects(9) = New MainObject

    Friday, November 25, 2011 4:00 PM
  • When you do all the testing, did you restart the PC, and make sure the Objects are released, else your memory will fill up quick, because you create Objects but not releasing them (or you might have this coded somewhere).

     

    I don't have Windows 7 Ultimate to test on, else I would glady run some tests as well.

    I can test on Vista, but results might differ on different operating system and specs.

     


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Saturday, November 26, 2011 2:03 AM
    Moderator
  • Thanks.... Danishani

    Your kindley approach.....

     

     


    • Marked as answer by Ichchu Monday, November 28, 2011 2:05 PM
    • Unmarked as answer by Ichchu Monday, November 28, 2011 6:39 PM
    • Edited by Ichchu Monday, November 28, 2011 6:40 PM
    Monday, November 28, 2011 2:04 PM
  • You might upload an example of your database on Skydrive (with non-sensitive data), so I will be able to do some testing.


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Tuesday, November 29, 2011 12:31 AM
    Moderator
  • Hi Dani...

    Sorry to reply late...but still I am busy with same error ...

    So,how could I upload my file on Skydrive ?

    and how u get this ?

     

     

     


    • Edited by Ichchu Tuesday, December 6, 2011 6:03 PM
    Tuesday, December 6, 2011 6:02 PM
  • You can goto this site:

    http://explore.live.com/skydrive

     

    Then follow the steps.

     


    Daniel van den Berg | Washington, USA | "Anticipate the difficult by managing the easy"
    Tuesday, December 6, 2011 6:12 PM
    Moderator
  • I have a very similar issue, MS Access 2007 Application work on Windows XP but not on Windows 7. Could you please let me know if you found a solution ? Thank you

    • Edited by vvtina Friday, December 9, 2011 7:19 PM
    Friday, December 9, 2011 7:18 PM
  • Hi Ichchu,

     

    If you move the same file you are working with now back to your Windows XP machine with Access 2007, does it still work there?  If you run a compact and repair with this file on your Windows XP machine, does that work?  Based upon the error messages you are receiving, I would agree with Daniel’s statement that it looks like you might still be experiencing some corruption within your database file.  If that is the case, we may be limited on what we can do.  At this point, the only other recommendations I have would be:

     

    +>Ensure you have SP3 for Office 2007 installed.  This service pack included a few performance fixes for Access 2007.  In your case, I don’t know that you are running into a performance type issue, but it wouldn’t hurt to install this and test.

    +>What happens if you run msaccess.exe in Windows XP compatibility mode?  To do this, navigate to msaccess.exe on your machine, right click on it and choose properties.  In the properties dialog, click on the compatibility tab and choose Windows XP (Service Pack 3) in the drop down selection for “Run this program in compatibility mode”.

    +>If this still works on your Windows XP machine and you can compact and repair the file on this machine successfully, then you could try creating a new blank database on that machine and import all of the objects from your database into this new file.  Then within this new file, make sure it still works on your XP machine and make sure you can once again run a successfully compact and repair.  If  you can, then move it to your other machine and test again.

    +>If the above steps fail, you could try making a sample database and recreate an object that makes use of the code you are trying to use to see if it works in this scenario.  If this works, then  you could try rebuilding this object in your original database.

     

     

    If the above suggestions don’t work, then my next recommendation would be to open a support case with Microsoft so one of us can look into the issue with you.  You can either create a case by calling in or you can use the link below:

     

    Online Assisted Support Options (create cases online) - http://support.microsoft.com/select/default.aspx?target=assistance

     

     

     

    VVTina,

     

    When you say you have a similar issue, are you receiving the exact same error or a different error?  If you are receiving the same error, then I would also recommend going through the steps listed above.  If you are experiencing a slightly different error, then it would probably be best to have you start a thread for the specific issue you are having.

     

    Best Regards,

    Nathan O.

    Microsoft Online Community Support

     

     


    Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
    Monday, February 6, 2012 4:48 PM
  • Hi Guys,

    Did we find any resolution to the above problem. I am also facing the same issue. Tried all the steps suggested by Nathan, but no luck.

    Any help is appreciated.

    Thanks,

    Puneet

    Sunday, March 4, 2012 12:19 PM