Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2004
    Location
    ny, ny
    Posts
    224

    Unanswered: still struggling with paste errors

    I have a time field with input mask as short time ie 12:12
    If the time entered is single digit hour eg 01:10 or 09:59 which then becomes 1:10 or 9:59 I am unable to duplicate the record using the duplicate button on my form. This is because when duplicated it doesnt fit the input mask because it then becomes h:mm
    Is there a way to get around this without removing the input mask
    My duplicate button is quite standard
    Private Sub transfer_Click()
    On Error GoTo Err_transfer_Click
    DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
    DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
    DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70
    Exit_transfer_Click:
    Exit Sub
    Err_transfer_Click:
    MsgBox err.Description
    Resume Exit_transfer_Click
    End Sub

    Can any one explain to me what thr 8, 2, 5 stand for

  2. #2
    Join Date
    Sep 2003
    Location
    MI
    Posts
    3,713
    Um ... If you'd read the docs on the DoMenuItem method you'd see that the 8,2,5 are the corresponding COMMANDS for Delete, SaveFormAs, and Cut ... And these are determined by their ordinal position in the list (or in Windows case: an enumeration).
    Back to Access ... ADO is not the way to go for speed ...

Posting Permissions

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