PC Review


Reply
Thread Tools Rate Thread

Calling a function on a form from another application

 
 
=?Utf-8?B?TWF1cnkgTWFya293aXR6?=
Guest
Posts: n/a
 
      21st Feb 2006
I'm trying to automate an Access app from Excel. The app writes out orders
for various products, and the Excel sheet has an inventory. That way the user
can select an item in Excel, click the "Order" button, and presto, Access
pops-up with a filled out order they can Save.

Only one problem: after the item is selected, there's a function that has to
fire on the form to fill in various info fields based on the selected item. I
can't figure out the syntax.

Here's the line that sets up the order and fills in all the defaults...

oAccessApp.Run "SetupOrderEditor", 0

I then look up the line in the temp table and poke in the proper ID. After
that I open the form with...

oAccessApp.Visible = True
oAccessApp.DoCmd.OpenForm "Order Editor", acNormal, , , , acDialog

So far, so good, but now I have to call that function...

oAccessApp.Forms("Order Editor").Run "UpdateSecurityInfo"

And that gets me a "form not found". Now I know it is found, because it's
open and looks great.

Any ideas? I seem to remember there's some simple but non-obvious syntax for
this.

Maury


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Best Means: Calling a Function or Application on a Remote Server jehugaleahsa@gmail.com Microsoft C# .NET 5 12th Mar 2009 01:17 AM
about calling a function of service from application pvenkatesh2k4 Webmaster / Programming 0 19th Mar 2008 05:16 AM
Unmanaged DLL calling back C++ Managed application function ... Ho =?Utf-8?B?SC5CLg==?= Microsoft VC .NET 1 1st Oct 2005 12:29 PM
Calling Outlook VBA function from another application Composer Microsoft Outlook VBA Programming 1 9th Apr 2005 06:22 PM
Calling VB.Net function from VB application Rudy Mark Microsoft VB .NET 4 24th Oct 2003 03:02 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:17 PM.