Page 1 of 2 12 LastLast
Results 1 to 15 of 18
  1. #1
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201

    Unanswered: MS Access Security

    Hello again, Colleagues All!
    Once again I must request your erudite assistance with a problem of Microsoft security. The context is that my client is a member of a community of businesses which about 10 years agocommissioned a developer to create a business system for them in Access 97. Each business has its own customised copy. I am developing a replacement system, but meanwhile some members of the community wish to upgrade the old system to Access 2003. There have been a number of problems, some of which seem to be associated with security.
    We tried to upgrade using the MS Access which comes with Office 2003. The upgrade broke down with Access reporting that it had to close andould we like to tell Microsoft. I then used my independent Access 2003 to convert the old program to the latest version and this worked. However, when we try to open the program we get a raft of errors which vary depending upon the circumstances.
    1. The desktop icon opens Access with the /runtime and /profile flags set. I was able to get into the system as Owner (using a batch file with the appropriate name and password). I deleted the code which tests for the profile and then removed the /runtime and the /profile flags. However, it still refuses to allow entry unless the runtime version and profile are used. I suspect that there is stuff buried in the registry somewhere which is clogging us up. Could someone please fill me in on these esoteric aspects of Access security or provide me with some good references. I have not much hair lft and I treasure what I still have, but frustration responses don't change over time.
    Jim Wright.

  2. #2
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    it still refuses to allow entry unless the runtime version and profile are used
    What do you mean by "refuses to allow entry" - data entry into one form, entry into the interface?

    Can you get access to the code in the application so that you can check references?

    If you can gain access to the code and you just can't do data entry, you should trace the code and find what it is that stops data entry.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  3. #3
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201
    The application has a front-end with all of the forms, queries, etc. and a back-end which holds only data. Links are refreshed propgrammatically on startup. When we try to start up the front-end, we receieve a message via MsgBox stating that we can only start up the program using the provided runtime and profile as defined n the desktop icon. we still get the message even when we have removed the /runtime and /profile flags from the icon command and commented out the checking code in the VBA. I suspect the Registry because on my home machine, where the development work is done, everything works just fine. Previously, I would work in Access 2000, convert it to Access 97 for the client, create a .mde file and copy it to the clients machine and everything worked. I was only able to upgrade the clients copy to 2003 by doing it on my machine and copying the .mdb file over to complete the setup. However, that pesky message still comes up.

  4. #4
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    You haven't given enough information for anyone to help you.

    From my point of view, I can just say to find the code that generates the "pesky message" and get rid of it.... whatever that message really is.

    Did you code it? If you did then YOU would know what parts of the registry were tampered with and whether or not they are the problem or not... whatever that problem really is.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  5. #5
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201
    The application referred to was written about 10 years ago by someone else. I have scanned the VBA code (nearly 20,000 lines of it !) and commented out everything that I thought could possibly have a bearing on the matter. All I did in my original post was to describe the symptoms and speculate on what might have been the cause. The opinion that there is insufficient info to offer advice merely illustrates the extent of my problem.
    I have since Googled around and found some old Access 97 references which may provide a way forward. It does seem to be related to the registry (and possibly the Jet version) and identifies one of those typically MS opaque addresses in which to look. I will pursue this matter and if a solution eventuates, I will report back to the forum.

  6. #6
    Join Date
    Apr 2004
    Location
    Kingsland, Georgia
    Posts
    231
    If you've converted it to access 2003, couldn't you just open a new 2003 database, import the database objects, compact/repair, set the startup form/code, put a breakpoint and debug through it?

  7. #7
    Join Date
    Apr 2004
    Location
    Kingsland, Georgia
    Posts
    231
    and maybe also got to the code window and compile it to make sure there are no broken references, etc.

  8. #8
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201
    Thank, you, colleagues,

    Yes, the suggested solution (build a new application from elements in the old one) is under consideration, but we are trying to avoid it if possible. The 10-year old application reflects the business workflows very well, but it was written by someone who did not understand the necessity for normalisation in relational databases, and all relationships are embedded in mountains of repetitive code. It will probably take more hours than the client is prepared to underwrite to effect the conversion.

    The situation is complicated by the fact that I am writing a new application for some other members of the same business fraternity to replace this one and I am trying hard to persuade everyone to hang on until the new one is ready. Anyway, thanks for the suggestions (and particularly the reminder to recompile - VBA is noteworthy for different versions giving different results for the same code).

    The matter of storing profile information in registry is intersting and may be relevant to others updating Access 97 across several later versions in one jump. If anything transpires, I will report back.

    Jim Wright.

  9. #9
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    I'm guessing their's some code in your mdb/mde which is not normally done or done differently in newer versions of MSAccess but was created in work-around fashion in the 97 version (ie. security). I'm assuming you have 1 or many modules being utilized and possibly some Window's environmental type calls (ie. calls to write/read from the registry as Star Trekker mentioned.) In the past I've written to the registry via MSAccess/vba but I stopped doing that as I don't think it's wise to mess around writting to the registry (especially if Window's might be upgraded in the future.)

    I'd be interested in seeing the code (especially any modules). Otherwise the only advise I could give you would be the similar to jmahaffie which is create a new mdb and import the objects into that mdb in stages, testing parts as you go. Especially look at any code which is executed when the mdb first opens. If you can troubleshoot and post the code which is executed when starting the mdb, we can help you diagnose it and any problems using the parameters you mentioned. Once the startup code is fixed (if that's determined to be problematic), then it's a matter of finding what other code is giving you problems.

    If you can't post any of the code, you may want to take some snapshots into a Word document and post that. I think we'll need some kind of code/screenshots posted though to help you diagnose and troubleshoot some of your issues. It's been a while since I worked in 97 and I can't think of anything to steer you to look at otherwise (my Access 97 books are sort of buried in the basement.)
    Last edited by pkstormy; 07-10-08 at 00:50.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  10. #10
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201
    Thank you pkstormy. I may take you up on your offer to review the code.etc. For the moment, this client (one of six in a community using the same applications) is still running OK on Access 97 and I have a pressure job creating a replacement for one of the other members who has ambitions not shared by the rest of the community (don't you just love office politics ?!) but as time permits, I will put together a comprehensive package as I do not want to waste your valuable time with only those bits I have currently identified. It seems to me that this could be quite a critical issue with users who have not progressively upgraded from Access 97.
    Another funny symptom in the same application which may be related. Some members of the community have "mislaid" their .mdb files after minor variations spearated them from each other. They are running on the .mde file. Normally when one enters a .mde file as owner, tables are visible and the data can be edited, though many of the menu options are greyed out. In this case, I can get in, but none of the tables are visible - all I have is a blank window. Has anyone seen this before ?

  11. #11
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Three possibilities:

    1. There are no tables in the design of the MDE, the forms may directly reference SQL Server data.

    2. The table links are created on normal startup, not just when the file is opened.

    3. The tables are all set to hidden and your setup doesn't allow you to see hidden tables.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  12. #12
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    Other than being hidden, I've seen tables (disappear) when I've edited one of the tables (but I then click on Forms or Queries and then back on Tables and they are there.) This has also happened with other objects (ie. forms, queries) when I edit one of them (ie. I have to click on Tables or Queries and then back on Forms after editing a specific form). Something with MSAccess XP and the refreshing of objects when you edit one of them. But if they are not visible when you first open the mde, I would try refreshing or possibly delete and relink the tables. Other than what StarTrekker suggested, it could also be due to a slow or bad network connection to the mdb with the tables or possibly even a problem with MDAC (although I doubt this but something to keep in mind.) I take it they are not visible even when opening the mde using the shift key? There is also a sample in the code bank somewhere where I had some code which allows you to set the attribute of the tables to hidden. When I made this code, I noticed that even though I un-hide them using the code, for some reason the specific code I used to hide them had set a flag which apparently didn't "un-hide" them correctly. I can't recall where this code is but it's in the code bank somewhere.
    Last edited by pkstormy; 07-13-08 at 14:51.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  13. #13
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    I have encountered that too... first time I saw it I think I turned white and my heart skipped a beat ^^
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  14. #14
    Join Date
    Oct 2004
    Location
    Melbourne, Australia
    Posts
    201
    Well, colleagues all, this conversation is producing some quite interesting stuff! I know what you mean about the sequence of events in Access processes. It was quite a surprise to find that the Current event actually takes place beofre the Open event is completed and one can be completely fooled by some of the delays in assigning values to variables and controls. Now, as it happens, I had a little hiatus with my current work, so I was able to put together a file as suggested by pkstormy and it is attached hereto. I also came across another little bit of info which may be helpful in resolving this little problem. The runtime directory contains quite a lot of .dlls and other stuff, most of which seem to be MS but perhaps there is some third-party material there. As a visiting alien from the planet of Unix and ksh, where everything is nicely separated in its own little neck of the woods, the depth of the interactions between Windows, Office and the various products thereof, I find quite mind--boggling at times. I have included a pic of the folder contents in the file.
    I look forward with interest to any comments you gurus may like to make.
    Attached Files Attached Files

  15. #15
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    No way I'm analysing THAT for free!! lol
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •