Pass command line parameters when running an application from a script.

  • Follow


In a FileMaker, is there a way to pass command line options.

The "open document/application" of the SendMessage command does not seem to
allow this.

TIA


0
Reply Harvey 2/11/2004 11:14:06 PM

Just use the filename as an argument to FileMaker to start the file
ex.
"PathToFileMaker\FileMaker.exe" "PathToFileMakerFileToOpen\FileToOpen.fp5"

/Johan Sundell

"Harvey Colwell" <harveyc@sds400.com> skrev i meddelandet
news:402ab73f$1_4@news.binaries.net...
> In a FileMaker, is there a way to pass command line options.
>
> The "open document/application" of the SendMessage command does not seem
to
> allow this.
>
> TIA
>
>


0
Reply Johan 2/12/2004 10:35:35 AM


This is not what Harvey is looking for. He wants to be able to pass an
argument to an external application. The argument could have more than one
value and will cause the application to execute different code each time the
argument is sent to the application. I don't see anyway to do this directly
from FileMaker and I haven't found a plugin that can do this. If anyone
knows of one, I'd even be interested in looking at it. It would be a
valuable tool.

Dave Herman

"Johan Sundell" <filemaker@sudde.no-ip.org> wrote in message
news:c0fkqi$169663$1@ID-189618.news.uni-berlin.de...
> Just use the filename as an argument to FileMaker to start the file
> ex.
> "PathToFileMaker\FileMaker.exe" "PathToFileMakerFileToOpen\FileToOpen.fp5"
>
> /Johan Sundell
>
> "Harvey Colwell" <harveyc@sds400.com> skrev i meddelandet
> news:402ab73f$1_4@news.binaries.net...
> > In a FileMaker, is there a way to pass command line options.
> >
> > The "open document/application" of the SendMessage command does not seem
> to
> > allow this.
> >
> > TIA
> >
> >
>
>


0
Reply David 2/12/2004 2:39:57 PM

This can be done with programs that are designed to accept command line 
parameters.  For example, I often send this command via the Send Message 
script step based off a field:

	"cmd /c rename ExportedFile.tab FinalData.txt"

Or, if you are looking for something else specific to a particular 
application, please let us know so we can perhaps help you come up with 
the proper solution.

David Herman wrote:

> This is not what Harvey is looking for. He wants to be able to pass an
> argument to an external application. The argument could have more than one
> value and will cause the application to execute different code each time the
> argument is sent to the application. I don't see anyway to do this directly
> from FileMaker and I haven't found a plugin that can do this. If anyone
> knows of one, I'd even be interested in looking at it. It would be a
> valuable tool.
> 
> Dave Herman
> 
> "Johan Sundell" <filemaker@sudde.no-ip.org> wrote in message
> news:c0fkqi$169663$1@ID-189618.news.uni-berlin.de...
> 
>>Just use the filename as an argument to FileMaker to start the file
>>ex.
>>"PathToFileMaker\FileMaker.exe" "PathToFileMakerFileToOpen\FileToOpen.fp5"
>>
>>/Johan Sundell
>>
>>"Harvey Colwell" <harveyc@sds400.com> skrev i meddelandet
>>news:402ab73f$1_4@news.binaries.net...
>>
>>>In a FileMaker, is there a way to pass command line options.
>>>
>>>The "open document/application" of the SendMessage command does not seem
>>
>>to
>>
>>>allow this.
>>>
>>>TIA
>>>
>>>
>>
>>
> 
> 

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Howard Schlossberg              (818) 883-2846
FM Pro Solutions       Los Angeles, California
Associate Member, FileMaker Solutions Alliance

0
Reply Howard 2/12/2004 3:56:22 PM

I've been able to get it to work. Under the FileMaker Specify Message script
command I still select "open document/application", but instead of
specifying a "File", I typed out the command line in the "Text" box option.
I had no problem including a parameter at the end of the command line.

I've read many issues about using paths with spaces, so I made sure that
there weren't any in the path to the external command (a vbScript file in
this case). Although I would like to note that I am using long file names
(both subdirectories names and the script's name have more than 8
characters).

----------------------------
With help for Dave Herman, I was able to find the registry value that
FileMaker used to hold it's default printer. I needed a way to automatically
switch this to a FAX driver, issue the print command, then switch it back to
the original print driver. I wanted to use only a single vbScript to switch
the driver in both directions. Therefore, I needed to be able to pass it a
command line parameter so it would know what to do.

The first time I run the vbScript the command line contains the parameter
"FAX". This causes the vbScript to backup the current driver information and
then replace it with the FAX driver information. The next time I run the
vbScript the, there are no command line parameters, this cusses the vbScript
to restore the backed up driver information.

Works like a charm!


"Harvey Colwell" <harveyc@sds400.com> wrote in message
news:402ab73f$1_4@news.binaries.net...
> In a FileMaker, is there a way to pass command line options.
>
> The "open document/application" of the SendMessage command does not seem
to
> allow this.
>
> TIA
>
>


0
Reply Harvey 2/13/2004 3:31:33 PM

4 Replies
716 Views

(page loaded in 0.06 seconds)

Similiar Articles:













7/23/2012 4:19:46 AM


Reply: