Recent content by IMO

  1. IMO

    deleting but not editing records

    The code should look like this... Private Sub delete_record_Click() On Error GoTo Err_delete_record_Click If MsgBox("Are you sure you want to delete the selected record?", vbYesNo, "Delete?") = vbYes Then Me.AllowEdits = True DoCmd.RunCommand acCmdDeleteRecord Me.AllowEdits = False Else...
  2. IMO

    How do I code to make an email object default to Rich Text

    This thread may help HTH IMO
  3. IMO

    Resetting Fields with macros

    You can't call it from the switchboard manager, how would it know which record to reset? Or do you only have one record in the entire db? The switchboard is related to no records, it acts as the control panel for your other forms etc. It is possible to reset ALL the fields in the table from the...
  4. IMO

    Resetting Fields with macros

    Change the code to... If MsgBox("Are you sure you want to reset the selected record?", vbYesNo, "Reset?") = vbYes Then Me.[Rent Paid] = 0 Me.[Date Rent Paid] = "" Else End If HTH IMO
  5. IMO

    Resetting Fields with macros

    No, not the switchboard. Select one of the forms that use Rent Paid and Date Rent Paid (Like an edit accounts form) and place the button on there. HTH IMO
  6. IMO

    Resetting Fields with macros

    Ok, Open the form where you view the data in design view. Create a button cancelling the wizard. Right click on the button and select properties, scroll down to "OnClick" and from the dropdown select "Event Procedure". Just to the right of the drop down arrow is another button " ... " click on...
  7. IMO

    Resetting Fields with macros

    Is this a switchboard created by the switchboard manager or have you created it yourself? IMO
  8. IMO

    Resetting Fields with macros

    Forget the macro, use this code in the OnClick event of the reset button... Me.[Rent Paid] = 0 Me.[Date Rent Paid] = "" HTH IMO
  9. IMO

    Resetting Fields with macros

    In the OnClick event of the button try... Private Sub YourButton_Click() Me.YourRentPaidField = "" Me.YourDateRentPaidField = "" End Sub When you say "will reset fields that I select", how are you selecting the fields? With a CheckBox? HTH IMO
  10. IMO

    Tab order - Different parts of form

    You could use the LostFocus event of the text box... Private Sub TextBoxName_LostFocus() Me.CommandButtonName.SetFocus End Sub but this will only move the focus to the button and you won't be able to tab back to the detail section. HTH IMO
  11. IMO

    UserLogOff

    To open the form hidden... DoCmd.OpenForm "YourForm", acNormal, "", "", , acHidden to hide the form after an event (LogOn)... Me.Form.Visible = False HTH IMO
  12. IMO

    manipulate excel file

    Place the following code in a new module changing "Sheet1" to the Sheet Name and "YourExcelWorkbook.xls" to the Name and path of the workbook... Public Function DeleteRowAddDummyData() Dim objXL As Excel.Application Dim objWkb As Excel.Workbook Dim objSht As Excel.Worksheet Dim...
  13. IMO

    Newb Question

    Create a query selecting the fields you want in your report. In the criteria field of the date column put... between [Start Date] and [End Date] get the wizard to create the report based on your query. HTH IMO
  14. IMO

    help me please emergency

    :confused: We'll need a little more information on what you want to do. IMO
  15. IMO

    making a form editable, not read only

    Try ... DoCmd.OpenForm stDocName, , , stLinkCriteria, acFormEdit HTH IMO
Top Bottom