Results 1 to 2 of 2
  1. #1
    gangel is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jun 2014
    Posts
    194

    Sub Procedure not using ME.Parent code

    Hey ppl,

    So i have a Form "Scripts" with ClaimID on it (Continuous form), which you type something in a text box and this opens a new form "CustomerSelect" using the AfterUpdate for the txt box




    NOW once you have selected the customer, it sends you back to "Scripts" and you move on.

    What I NEED to do is run a code (GenerateInvoice) that takes me.claimID from the record you were typing in.

    I need this code to run when you get back from "Customer Select" form

    I originally had
    "Call GenerateInvoice"

    Which would run the code after selecting a customer.
    It would close the customerSelect Form then go to GenerateInvoice... But I keep getting an error as It says i cant use "Me.Parent" or even "Me.ClaimID"

    Just trying to figure this out.

    Hopefully I'm clear...

    Scripts:
    - Type in text box
    -After update text box sends to CustomerSelect Form.
    -After select Customer go Back to Scripts Form
    -Run "GenerateInvoice" sub, using the me.claimId codes

    Thanks for any advice ppl

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,530
    I'm a little confused, but if GenerateInvoice is a public function in a standard module, you can't use "Me". You'd have to use the full form reference or pass the value to the function as a parameter.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. Replies: 6
    Last Post: 02-24-2015, 01:19 PM
  2. Replies: 3
    Last Post: 08-14-2014, 01:17 PM
  3. code referenceing stored procedure put in recordset
    By seeker63 in forum Programming
    Replies: 3
    Last Post: 12-05-2013, 01:47 PM
  4. Replies: 1
    Last Post: 07-08-2011, 10:26 AM
  5. Replies: 4
    Last Post: 05-18-2011, 03:24 PM

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