Results 1 to 11 of 11
  1. #1
    Join Date
    May 2009
    Posts
    8

    Unanswered: Add sorting to a table

    hello. i am running an Access 2003 MDE and i was wondering what the best way to go about doing this was. When a user opens a table, i want them to be able to sort on any given field. for example, if thay want to sort on the date, is it possible for them to click on the field header and make it sort? i know that this question is easy if you arnt using an MDE, but what i did was i went to Tools/startup and disabled all the menus. this essentially made my executable... and now wont let me right click on the fields. is there any easy way to go about doing this?

    Valgore

  2. #2
    Join Date
    Sep 2002
    Location
    South Wales
    Posts
    580
    User + Direct access to table = impending doom!

    Maybe provide them with a continuous form and have buttons for each header - change the ORDER BY clause of the query behind the continuous form when they click each button.

    Are they opening up whole tables of data???
    Windows Server 2003-8 / Terminal Services / SQL 2000 / Access 2003 / Office 2003-7 / Exchange 2003-7 / Blackberry Enterprise Server / AutoCAD / Lambert And Butler / Red Bull

  3. #3
    Join Date
    May 2009
    Posts
    8
    well. this application is being used for 6 people and they are all very good friends of mine, so this MDE isnt as secure as it can be. the president wants to be able to easily look at all the charges for the current month, and they are in that table. i trust him completely. i found out how to make it work, when i went to Tools/Startup, i checked Allow shortcut menus or something like that at it now allows him to right click and sort. so thanks for the quick reply.

    Valgore

  4. #4
    Join Date
    Sep 2002
    Location
    South Wales
    Posts
    580
    No problem sir, as long as you are happy;

    I would however highly recommend you build a report or form which provides this information - what is going to happen when the amount of data grows over time?

    What will you do *if a user accidentally deletes a field, row or dare I say it whole table?

    * I think I mean 'when'

    Be careful out there and if nothing else, make sure you have a very, very good back-up system in place!
    Windows Server 2003-8 / Terminal Services / SQL 2000 / Access 2003 / Office 2003-7 / Exchange 2003-7 / Blackberry Enterprise Server / AutoCAD / Lambert And Butler / Red Bull

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Don't give users access to your tables.

    I don't think you can save the sort order of a table tbh. When the database is closed and re-opened the order of records is in PKF order again. I think. Not sure as I never ever ever allow users access to tables.

    The alternative, which is probably already mentioned, is that you could save some queries with preset sorting in them for [advanced] users to get at.

    I still wouldn't do it though.
    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

  6. #6
    Join Date
    May 2009
    Posts
    8
    ok. thanks you two. i will give the form idea a try.

    Valgore

  7. #7
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    No!!

    DO... or DO NOT.... there is no try!
    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

  8. #8
    Join Date
    May 2009
    Posts
    8
    ok i did what you guys said and it works great. thanks for the responses!

  9. #9
    Join Date
    Sep 2002
    Location
    South Wales
    Posts
    580
    Well done and remember, a Jedi's strength flows from the Force!
    Windows Server 2003-8 / Terminal Services / SQL 2000 / Access 2003 / Office 2003-7 / Exchange 2003-7 / Blackberry Enterprise Server / AutoCAD / Lambert And Butler / Red Bull

  10. #10
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Yes, to garethdart you listen, mind what you have learned, save you it can!

    Glad you got it sorted Valgore
    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

  11. #11
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    Quote Originally Posted by garethdart
    Well done and remember, a Jedi's strength flows from the Force!

    ...whereas a developers strength flows from the source (code)......
    I'd rather be riding on the Tiger 800 or the Norton

Posting Permissions

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