Results 1 to 8 of 8
  1. #1
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228

    Project Managment

    I have a database that will deal with all aspects of a project. That's great. But currently when I want to use it on other projects or make a new project, I have to make a new front end that is specifically for that project.

    What I'm doing now (working progress/subject to change) is having the user select the project on the main menu. This information will then be kept on an invisible text box on the background form.

    Then, Any main form that opens from the menu will use this information in the query and only open information relating to that project. That's the best way I can think of for doing this. Any suggestions appreciated.


    So, assuming that solution is the one I go with (its the one I'm working on). I'm having a few problems. This is code associated to the change event of the combo box on the main menu.

    Code:
    Private Sub project_Combo_Change()
    DoCmd.Requery "project_combo"
    Forms![background form]![Project_ID].Requery ' <- error occurs on this line
     
    End Sub

    I cant get either of these lines to update what's on the background form, the error I'm getting is: 438 : object doesn't support this property or method

    I've had a look online and I'm confused as to what's causing it to be honest.

  2. #2
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228
    Changed it to:

    Code:
    Forms!background_form!Project_ID.Requery
    getting the same error. NOTE: I have changed the name of the background form to include the underscore.

    Its a syntax problem from what I read, ill keep looking.

    then I've tried this:

    Code:
      Dim ctlCombo As Control
     
        ' Return Control object pointing to a combo box.
        Set ctlCombo = Forms!background_form!Project_ID
     
        ' Requery source of data for list box.
        ctlCombo.Requery
    I get type mismatch with this one.

  3. #3
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    okay - so let's review:
    1. make a new front end that is specifically for that project: ** that is a horror show to be avoided at all costs

    2. having the user select the project on the main menu. This information will then be kept on an invisible text box on the background form. Then, Any main form that opens from the menu will use this information in the query and only open information relating to that project.
    ** yes - this is the correct approach and is often used whenever one needs users to log in and to only show their information. This of course is all premised on that selected value being included in a field of every relevant table so that it can be filtered by a query

    first - make your life simpler by putting that (hidden) value directly in a main form and not a sub form
    second - give yourself a Start screen that opens initially and serves no other purpose than selecting the Project plus to hold buttons to the next screens/reports that people will go to - - this eliminates the requery requirements altogether
    third - all object record set queries then have a criteria which calls to the (hidden) field held in the Start screen
    forth - if a single user is going to change between projects - make that occur only on the Start screen - and rather than requery open forms/reports - force close them....this will in turn force the user the press the button on the Start screen and thereby refresh the data...

    this approach is much less complicated and far more uniform and robust

  4. #4
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228
    The database was only used and built for one project, and its amended/updated on a priority need for the business. I agree it needs to be avoided. I have some questions, and I probably wont be looking to implement this until Monday now.


    I agree with what you're saying I'm just struggling to visualise it. I may be making this more difficult than it needs to be so ill have a go Monday then update.

    Thanks for the advice.

  5. #5
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    Fundamentally you need to insert a new Start screen that is the Project Selector - - and then take away any project selection from all the other screens, and rework their record source queries so they rely on the Start screen for the correct project criteria.

  6. #6
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228
    I understand that, but doing it that way requires the start screen to always be available?

    Not a problem im just asking.

    Theres not like a temporary memory after selection, It will always refer to that location. (I didn't get the chance to try this out, but thanks for your input)

  7. #7
    NTC is offline VIP
    Windows 7 64bit Access 2013
    Join Date
    Nov 2009
    Posts
    2,392
    I recommend the Start screen approach. With tabbed screens it just ends up sitting on the left and is easy for user to return to in order to select a different project. It makes it very clear to all as to which project is being worked on....But yes you can use a hidden form/screen to hold the value or do a DLookUp to call it from a table - or write it as a global variable to a module.

  8. #8
    Join Date
    Jun 2015
    Location
    Wales. Land of the sheep.
    Posts
    1,228
    Thanks, I'll be able to work something out with your suggestions. Now all I need is time! haha

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Multi-Location Inventory Managment System
    By lzook88 in forum Database Design
    Replies: 8
    Last Post: 09-04-2015, 02:58 PM
  2. Document managment
    By Homegrownandy in forum Access
    Replies: 4
    Last Post: 08-06-2015, 06:56 AM
  3. Stock Managment Database Design
    By chuki2 in forum Database Design
    Replies: 4
    Last Post: 12-22-2011, 11:36 PM
  4. Property Managment Form
    By JennyHunt in forum Forms
    Replies: 0
    Last Post: 03-02-2011, 08:30 AM
  5. Vessel managment database
    By elviscenko in forum Database Design
    Replies: 1
    Last Post: 03-13-2010, 08:52 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums