Search results

  1. W

    Newbie signing on!

    As a fellow Canadian, welcome to the forum. I've been a member for a few years now, and everyone has been very helpful to me.
  2. W

    closing form recalls form opened from

    Hi Pat, How would you do it if the calling form is from a button on a subform of a main form?
  3. W

    Hyperlink or Attachment

    Thanks. Worked perfectly. Wayne
  4. W

    Add one digit or plus one help in table field

    Hi Pat, I use this code to trap duplicates: Private Sub OrderNumber_BeforeUpdate(Cancel As Integer) Dim Answer As Variant Answer = DLookup("[OrderNumber]", "tblOrders", "[OrderNumber] = '" & Me.OrderNumber & "'") If Not IsNull(Answer) Then MsgBox "Order Number...
  5. W

    Hyperlink or Attachment

    Any thoughts on the best place to put that code to follow the hyperlink?
  6. W

    Add one digit or plus one help in table field

    Hi Colin, Just checked my Orders table. My invoice number field is a Short Text field type, and that code works on my form to select the next invoice number. As long as the data in the field is numeric only, it works. Put an alpha character in there and it crashes. Hope this helps. Wayne
  7. W

    Add one digit or plus one help in table field

    Hi Colin, Ya, you got a point there. I use it to generate the next numeric invoice number when I am ready to bill out a finished job. It won't work with an alpha-numeric field. I thought he was asking how to advance 00765 to 00766 on the next record, and so on. If he needed an alpha numeric...
  8. W

    Add one digit or plus one help in table field

    Here's what I use: If IsNull(Me.YourFieldName) Then Me.YourFieldName = Nz(DMax("YourFieldName", "YourTable"), 0) + 1 Else Exit Sub End If I put this in the OnClick event of a command button to generate the next number, but you could put in in the BeforeUpdate event.
  9. W

    Hyperlink or Attachment

    I read a reply to a thread by Doc Man about this. I set up a subform to enter the file path for stored documents relating to a job on the main form (as opposed to an attachments field). Should the field be set up as a hyperlink, and what code would you use to open the file to view it? The files...
  10. W

    Using VBA and the Visible Option

    Ridders is right. The problem seems to be the code needs to be in the On_Current event, not the On_Click event.
  11. W

    Hi Everybody

    Welcome aboard.
  12. W

    form verification

    I'm not sure if Static is right, and why your form doesn't go to a new record once a complete record is entered. But to warn your user not to change an existing record you could try a message box in the Before Update event of the PO Number field: If Not IsNull(Me.PONumber) Then If MsgBox...
  13. W

    Hi all!!

    Welcome aboard.
  14. W

    Turn a query Formula into a function

    Try this from Allen Browne. It works great for turning and SQL statement into VBA code. http://www.everythingaccess.com/tutorials.asp?ID=Easily-copy-an-SQL-statement-from-a-query-to-VBA
  15. W

    Item not in Collection

    Thanks Steve. Tried that, but still getting the same error message. I double-checked all of the table and field names to make sure they are right (and they are), but I still can't figure it out. Any more thoughts? Wayne
  16. W

    Hello from Long Island, NY

    Welcome to the forum. It's always good to have another experienced user with us.
  17. W

    Hello From Cleveland, OH, building 1st database!

    Welcome to the forum David. I hope you find what you are looking for.
  18. W

    Item not in Collection

    I posted this about a year ago, and was getting query problems. I played with it and solved the query problem, and then was getting an error message saying "Too few parameters. Expected 1". So again I played with it. As near as I could figure it, Access was having a problem with the Form, so I...
  19. W

    Open form to a record with today's date

    I need new glasses! It works perfectly. Thanks once again. Wayne
  20. W

    Open form to a record with today's date

    Hi Paul, Tried this code, and it opens up all records, but it goes to the first record in the database. Did I code it right? Private Sub btnOpenOrders_Click() On Error GoTo Err_btnOpenOrders_Click Dim rs As Object DoCmd.OpenForm "frmOrders" Set rs =...
Back
Top Bottom