Results 1 to 6 of 6
  1. #1
    turbo910 is offline Novice
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    21

    Delete record harder than it seems

    Hey guys


    On a form i have got a combo box for the Product_Name [Product] and 3 text boxes linked to the combo box to show quantity[Product_Qua], unit[Unit] and section[Section] for the product. They are linked to the combo box by the =[Product].[Column](2) command.

    All i want to be able to do is when the user finds the product he/she wants to delete is click a delete command button and there we go record deleted.

    Ive tried the wizard but doesnt work and i dont know any code so yeah couldnt write my own script.

    Could anyone please give me some instuctions and code or w.e resources i need to be able to do this. Thankyou

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    You mean the command button wizard does not know how to delete the current record?

  3. #3
    turbo910 is offline Novice
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    21
    Its ok dude ive sorted it thankyou

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Care to share your solution with the others that read this forum? What to follow the link in my sig and mark this thread as Solved?

  5. #5
    turbo910 is offline Novice
    Windows Vista Access 2007
    Join Date
    Nov 2009
    Posts
    21
    FromMissinglinq in another forum

    If you haven't already done so, create a form based on your table or query, including all the fields you want displayed.

    Or you can make the form you already have bound to the table/query by setting it as the RecordSource for the form, then for each textbox selecting the appropriate field in the table/query as its Control Source.

    Then simply:Add a ComboBox to your form.

    The Combobox Wizard will pop up

    Select "Find a record based on the value I selected in my combobox."

    From the table or query the form is based on, click on the field you're searching by (a field that is unique for each record) to move it to the right side.

    Hit Next.

    Size the column appropriately.

    Hit Next.

    Name the ComboBox.

    Hit Finish.

    Now you can drop the ComboBox down and scroll down to the item to search by, or you can start to enter the item, and the ComboBox will "autofill" as you type. Hit <Enter> and the record will be retrieved.

    Once the record is retrieved, a standard Wizard generated Delete Button should work just fine.

  6. #6
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows XP Access 2002
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Thanks for the follow up.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 08-28-2009, 05:16 AM
  2. Command button help - delete record
    By Zukster in forum Forms
    Replies: 0
    Last Post: 08-27-2009, 08:47 AM
  3. Delete erroneous record(s)
    By jgelpi in forum Programming
    Replies: 4
    Last Post: 07-10-2009, 07:08 AM
  4. Two Delete Record Problems
    By skyrise in forum Programming
    Replies: 1
    Last Post: 04-22-2009, 09:37 PM
  5. Delete a record
    By f.crocco in forum Programming
    Replies: 1
    Last Post: 10-08-2007, 07:28 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums