Search results

  1. Wiz47

    Class Roster entry and delete suggestion

    Private Sub CmdDelete_Click() ‘Create the message box to warn that deletion is permanent. If MsgBox("Deleting will permanently DELETE the Record" & vbCrLf & " Do You Really Want To Delete It?", vbInformation + vbYesNo, "DELETE RECORD!") = vbYes Then ‘Turn warnings off DoCmd.SetWarnings...
  2. Wiz47

    if condition

    You might also consider an else statement in case the values do not equal the ones indicated. The else statement would tell the program what to do if the conditions aren't met.
  3. Wiz47

    Using a Text Box to Find a Specific Record

    I would suggest that as well. Typically, I use the name of a person to search for a record, then display it. But they could use the record number directly if they preferred. The code below is what I use for that purpose. Private Sub Cborecord_AfterUpdate() On Error GoTo Err_Record_AU...
  4. Wiz47

    Else without if

    Thanks to all in the thread. I just had it blocked out incorrectly.
  5. Wiz47

    Else without if

    You're correct. I needed to block it out properly. That's what happens when you work on code all night. Thanks.
  6. Wiz47

    Else without if

    It seems to me that my syntax is correct. Why the error? Compile error: Else without if
  7. Wiz47

    Popup Calendar

    I use the zsCalendar for a quick popup calendar that I attach to a button on the Onclick event. You can find it here ... http://allenbrowne.com/ser-51.html
  8. Wiz47

    How Can I Change these If Statements into a Case Statement?

    Yes, especially when trying to convert 2007 DBs to 2010. Oh ... what fun.
  9. Wiz47

    Use and Display Data in table other than one being used

    If you want to declare global variables, an easy way to do it is in a module. The variables defined in the module will be available to all of the forms in your program. Below is a snippet from the module used for zscalendar.
  10. Wiz47

    Pre-populate form fields

    This is how I do an autofill on a form reading from a combobox.
  11. Wiz47

    Is it ok to have Field names with spaces?

    Very good points. I would also add that the names of ALL controls should also follow the name of the Source. For example a field named Lastname should have a corresponding text box control named txtLastname. That way it is much easier to keep track when you are trying to build queries and/or...
  12. Wiz47

    Search forms

    I use something very similar in a contacts form. I love the way it will narrow a search based on *any* criteria in the fields, dynamically. And like yours, a double click on the highlighted bar will bring up another form with the full information in that particular record.
  13. Wiz47

    Filter Subform results based on Main form unbound field

    Here's a snippet from a program I use that changes the subform based on the unbound field selection in the main form. SELECT tbl2010_Data.* FROM tbl2010_Data WHERE (([Date_recvd]=Forms!frmSearch!txtDate_Recvd Or forms!frmSearch!txtDate_Recvd Is Null)=True) ORDER BY [Date_recvd];
  14. Wiz47

    How to clear fields in acNewRec

    I use this to "clear" fields in a form that is a subform in a search box when a command button "Clear Form" is pressed. You should be able to adapt it for your use. Note that the names are for the text boxes in the form and NOT the actual fields in the DB. On Error GoTo Err_CmdClear_Click...
  15. Wiz47

    database bulge

    Here's an article (a bit dated) but it has very good explanations as to why a database might grow rapidly, and what we can do about it. Doing all major changes on a "working copy" has been a technique I use. Then I transfer the code or object to the real database...
  16. Wiz47

    First and Last name in Form - what is the best way to handle this?

    Truer words were never spoken. [First Name] & " " & [Last Name] is always the better approach.
  17. Wiz47

    Compact on Close

    Good advice. I have never had an issue with Compact and Repair either, but having a backup of the DB is always the best policy.
  18. Wiz47

    Access Levels - Security

    The example uses User Levels to limit access after login. The followng are the login names and passwords. This is but one way to accomplish what you want, but at least you will have a basic example to work from. John 111 James 222 Edward 333 Fred 444
  19. Wiz47

    Diplaying query results in a form

    If the fields are basically the same for all the searches, then use a combo that opens a separate form and uses the combo selected query as the record source. I use this method to create different reports for various querys that use the same report template. If you have different forms for...
  20. Wiz47

    Need help: FindRecord question (acSearchAll is not searching all)

    You also have the option of creating a combobox and selecting the name of the employee (then have it go to that record) the combo can list all the names in alphabetical order so similar names will be next to each other.
Back
Top Bottom