How to compile Access database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • DavidPT
    New Member
    • Oct 2008
    • 44

    How to compile Access database

    Hi all,

    I have setup a database and am trying to figure out the best way to compile it as a few people are using this database.
    At the moment if someone logins to the database at the same time as someone else they are locked out of it and only given the read only version.

    Whats the best way to fix this?
  • PianoMan64
    Recognized Expert Contributor
    • Jan 2008
    • 374

    #2
    Originally posted by DavidPT
    Hi all,

    I have setup a database and am trying to figure out the best way to compile it as a few people are using this database.
    At the moment if someone logins to the database at the same time as someone else they are locked out of it and only given the read only version.

    Whats the best way to fix this?
    Hey DavidPT,

    Welcome.

    To solve you issue, this is what I suggest that you do.

    1. If you haven't split the database yet into Data Table in one, and all the other Queries, Forms, reports, Macro and Modules in another, please do so.

    2. Once that is completed, you need to make sure that you have a Network shared directory that has Read,Write, Change Permissions for all users of the database.

    3. Copy the MDW (User Workgroup File) and MDE (Compiled Version of your database) file that you have for your application to the Network Share.

    4. Have each user copy the MDE file to a local directory that has all the forms, etc onto there local computer.

    4. Then when they log in make sure that the MDW file that you're pointing too is located on a Network shared drive as described before in option 2.

    5. Once all that is setup, this should take care of your problem.

    If you have any more questions, please feel free to let me know.

    Thanks,

    Joe P.

    Comment

    • NeoPa
      Recognized Expert Moderator MVP
      • Oct 2006
      • 32633

      #3
      Front-End / Back-End (FE/BE) will possibly help with the splitting. This is generally recommended for multi-user Access databases.

      However, I should point out that read/only, when opening an Access database, refers to the design rather than the data. It is still possible for the users to use it in that mode.

      Comment

      • DavidPT
        New Member
        • Oct 2008
        • 44

        #4
        Thanks for the replys,

        I was able to compile it and all users can use it without a problem. Is it possible to uncompile once it has been compiled?

        Comment

        • NeoPa
          Recognized Expert Moderator MVP
          • Oct 2006
          • 32633

          #5
          Every time a design change is made, the project is flagged as uncompiled. I doubt this means that every object loses the benefits of being compiled, but I'm not sure. Certainly it enables the Compile [project name] option in the Debug menu.

          Comment

          • missinglinq
            Recognized Expert Specialist
            • Nov 2006
            • 3533

            #6
            The question "Is it possible to uncompile once it has been compiled?" makes me think it's possible that you're being confused by the term "compiled" as it applies to an Access database.

            "Compiling" an Access database is not the same as "compiling, " say, a Visual Basic program. When you do that to a VB program, all code is "locked and hidden" from the users, and it can be run by any PC, whether or not there is a copy of Visual Basic on that PC.

            This is not true when "compiling" an Access database. Access basically just checks all code in the app for correctness. End users still have access to code and can still make design changes, and thus you don't need to "decompile" it in order to make changes.

            In addition, a "compiled" database cannot be run on a PC that 'doesn't have some form of Access on it. It doesn't have to be a full version of Access, it can be what is know as a "runtime" version, but, unlike a compiled VB program, there has to be some version of Access on board.

            You can, after compiling an Access database, convert it to an MDE file, as Joe mentioned, and this will "lock" it from code/design changes by the end users, but they will still need some version of Accesss on board to run it.

            Linq ;0)>

            Comment

            • OldBirdman
              Contributor
              • Mar 2007
              • 675

              #7
              I would love to convert mine to an MDE file. Tools->Database Utilities->Make MDE File...produces "Microsoft Access was unable to create an MDE database" when "Save" pressed in "Save MDE As" dialog. No message number, no help, no nothing.
              My choices are "OK".

              Comment

              • DavidPT
                New Member
                • Oct 2008
                • 44

                #8
                Thanks again for all the reply's,

                My access database has been compiled as a MDE file. It allows me to design new queries but will not allow me to design any reports or even modify any reports. So im guessing that its locked me out, is there any way of fixing this? or will i just need to design the reports from my original MDB file and then compile it again?

                Comment

                • missinglinq
                  Recognized Expert Specialist
                  • Nov 2006
                  • 3533

                  #9
                  Yes, David, all design changes need to be made in the original MDB file, then re-compile and covert to MDE again.

                  BirdMan, you need to go into the code module for any form in your app, select

                  Debug from the Menu, then select

                  Compile xxx,

                  wher xxx is the name of the database.

                  Access will then tell you about any problems it finds anywhere in the database, so that you can fix them. After repeating this until it compiles without errors, you can go back as you did previously and convert to an MDE file.

                  You've been at this long enough to know, Bird, but I'll state it for newbies who may come here later on; you have to store the MDB file in a safe place, because any modifications you make later will have to be done with the MDB file. An MDE file cannpt be modified!

                  Linq ;0)>

                  Comment

                  • OldBirdman
                    Contributor
                    • Mar 2007
                    • 675

                    #10
                    Longevity is not a guarantee of knowledge. Thank you for the answer. I guess I've orphaned some event procedures when I deleted controls, so it won't compile.

                    Having never tried before this project to make an MDE, I just thought that I just had to choose Save As MDE.

                    Comment

                    Working...