Search results

  1. josephbupe

    Listbox returns empty before applying filter

    Ok, I have reviewed the code but still not returning all records. I am not sure what I am missing since no error is generated. Here is the code: SELECT Q_Gender_Statistics.ParticipantID, Q_Gender_Statistics.Gender, Q_Gender_Statistics.Date, Q_Gender_Statistics.Year, Q_Gender_Statistics.[First...
  2. josephbupe

    Listbox returns empty before applying filter

    Hi, I am using two combo boxes to filter a list box with the code below. The combo boxes work, but when the form opens, the list box is empty until it is filtered using the combo boxes. I want the list box to return all records when no filter is applied. Here is the code: SELECT...
  3. josephbupe

    Question Trapping errors when no query criteria is given in MS Access

    Thanx Trevor. I have only added an error handler behind the PRINT button. I am not seeing the need to have the error trapper behind the report itself since the database does not show preview of the report upon pressing the PRINT button. It only sends to the printer. This is the new code: On...
  4. josephbupe

    Question Trapping errors when no query criteria is given in MS Access

    I followed your advice. But still I can't get a custom error message. Private Sub Report_NoData(Cancel As Integer) MsgBox "Sorry, there was no search criteria" Cancel = True End Sub By the way, the database does not open preview of reports, clicking the PRINT button only sends the report...
  5. josephbupe

    Question Trapping errors when no query criteria is given in MS Access

    I am writing a small database using MS Access 2007. I have in it a function for running queries and printing reports. Printing works just fine if any one of the multiple query criteria is give. I also want to trap errors and present a message if the user clicks the "Print" button without...
  6. josephbupe

    Select multiple columns from two tables for searching

    Hi, Just starting with web databases. I have about six tables which are joined with a junction table called "t_incident_persons" as shown below: t_persons +-----------+-----------+----------+----------+ | PersonID | FamilyName| FirstName| CountryID|...
  7. josephbupe

    Question Inserting a default value from code

    I want to insert OfficerID of the officer currently logged in as a default value into the table T_FileCases when they create a new record. Already in the login form I have a field that holds the OfficerID when logged in successfully. Is it anything close to this?: Private Sub...
  8. josephbupe

    Error trapping

    Thank you JHB. Stay well.
  9. josephbupe

    Error trapping

    Hi JHB, I don't follow. How do I set the recordset?
  10. josephbupe

    Error trapping

    Hi, Please, I have limited logic capability on this. The text boxes for search criteria and the SEARCH button are on the main form while the search results are on a pop up form. I do not want the details form to open if the provided criteria does not match with any record in the database...
  11. josephbupe

    Question Login to see own records but admin to see all records

    That worked fine. Thank you Paul.
  12. josephbupe

    Question Login to see own records but admin to see all records

    Sorry about that. Please, try this one. Open F_FileCases. ADMIN: Username: joseph Password: joseph USER: Username: kennedy Password: kennedy Thanx.
  13. josephbupe

    Question Login to see own records but admin to see all records

    Hi Paul, The form I am restricting is a subform. Not sure I can use the open event. See attached copy of the mdb file. Thanx.
  14. josephbupe

    Question Login to see own records but admin to see all records

    Thanx for your response. But, I am still not sure about changing the record source of the subform open event. Are you saying avoiding the criteria? If so, how would that work?
  15. josephbupe

    Question Login to see own records but admin to see all records

    Hi, I have a user login code am using for users to login and only access their records in a subform according to their user ID and access level (user or admin). On the main form I have a user name field, the password field and two other fields: one to hold userID and the other to hold access...
  16. josephbupe

    Error traping for dynamic querydef

    My dynamic query keeps deleting when an error occurs i.e if the user did not supply query criteria before pressong the "Search" button. Instead I want a message box to pop-up when an error occures. I do not need to remove this line: db.QueryDefs.Delete ("Q_ImageNormalSort_MySQL") because...
  17. josephbupe

    David Crake – very sad news

    My condolences to the family on the lose of such a great man. He helped me on many occassions and I will personally miss David Crake. MHSRIP
  18. josephbupe

    Question Details form from multiple image controls on main form

    Hi, I have different challenges coming up each time I move from one stage to the other with my project. I am adopting a sample posted here for browsing multiple images in MS Access form. Everthing works fine so far, except I cannot open a details form with records specific to the image clicked...
  19. josephbupe

    Question Details form for an unbound control in MS Access

    Hi, I am trying to modify a sample by Roggers here for my project to browse multiple images in MS Access form. But, I would like to know how I can add an on-click event for the image control to open a details form. The code behind the form is as follows: Private Sub...
  20. josephbupe

    Question Help with table deffs query

    Hi, I have a listbox with values that query a table deff querry. The listbox is working fine. I want also to add a few text boxes to run queries in a similar manner but I am getting a syntax error. The code is as follows: Private Sub Command0_Click() Dim db As DAO.Database Dim QD As...
Back
Top Bottom