8 Replies Latest reply on Jun 10, 2015 8:22 AM by electon

    Execute a windows command on a network

    siplus

      On the same local network, we have

       

      - A filemaker Server

      - x macs running our solution

      - a windows machine connected to medical equipment.

      N.B. : All IP's are fixed.

       

      I am on one of the macs, looking at patient data inside our Filemaker solution.

       

      I need to implement the transfer of some info to the windows machine (Patient ID, full name, birth date, etc)...

       

      The windows machine is running a proprietary software, but is offering me some commands, like

      PatImport.exe <filename.txt>. Writing the file to a common directory is not a problem for me, but invoking the PatImport.exe command on the windows machine @ IP address xxxx with the known parameter (can be a file path or a text in quotes) from my Filemaker session on the mac is.

       

      Any ideas ?

        • 1. Re: Execute a windows command on a network
          electon

          I'm almost sure there's a plugin that does that already.

          Probably you could use telnet. Works Mac > Win.

          Set up a telnet server on windows machine if possible, connect and run the command.

          In many ways it works like ssh.

          • 2. Re: Execute a windows command on a network
            Menno

            Is there a filemaker client running on the remote PC? If so, then you could consider using the "troi-activator" plugin: http://troi.com/software/activatorplugin.html

            Another way maybe using Windows PowerShell, but I have not used it myself, only heard from a sysadmin that it is easy to use.

            • 3. Re: Execute a windows command on a network
              nicolai

              I would use telnet, as suggested by electon or ssh.  You would need to install ssh server for ssh e.g. freeSSHd.

               

              Both could be invoked from a FileMaker client through AppleScript.

               

              An alternative is to try to trigger the cmd command with update to a target folder. There are some programs which can do that ( e.g. Watch 4 Folder) or you can write your own VBScript to do the same thing.

              • 4. Re: Execute a windows command on a network
                siplus

                Thanks Menno,

                 

                there's no FM running on the client - we would like to avoid adding an additional FM license to the client's overall expenses if possible.  We do consider it as a last resort, and we're already registered users of Troi Activator.

                • 5. Re: Execute a windows command on a network
                  ariley

                  FileMaker Clients on annual licenses are cheap nowadays. Why is that the last resort? Why are you trying to jump through hoops to get to something you can do easily with FM?

                   

                  If we look at the cost of the developer’s time, vs. the cost of one more license, I’m sure the license wins.

                   

                  You can’t run an AppleScript on Windows, only on Mac. But there is VB Script.

                  • 6. Re: Execute a windows command on a network
                    siplus

                    Agnes Riley wrote:

                     

                    FileMaker Clients on annual licenses are cheap nowadays. Why is that the last resort? Why are you trying to jump through hoops to get to something you can do easily with FM?

                     

                    It's not the cost only. Often these medical equipment suppliers don't agree installing other software on their machines. No TeamViewer, no FileMaker, nothing.

                     

                    Example of a reply from the manufacturer:

                     

                    neither the image server nor the scanhead accept connections on port 25 (or any other telnet port) and it is not something we would recommend as this allows unencrypted traffic to flow to those network points.

                    • 7. Re: Execute a windows command on a network

                      I'm looking at the Miscellaneous menu in the script editor.

                       

                      There are a few options in the Windows version:

                       

                      These 2 might be useful.

                      Perform AppleScript

                      Execute SQL

                       

                      These 2 might have the ability to do what you want but may not be available on a Mac.

                      Send Event

                      Send DDE Execute

                      • 8. Re: Execute a windows command on a network
                        electon

                        Well, in that case I'd start by asking the manufacturer a "what do you allow?" question.

                        Judging by the response they have a deeper knowledge beyond the "we just installed the program" standard.

                        Something has to be done on that machine that will listen on the network.

                        I suggested telnet because it was there since forever and didn't think no encryption would be a a huge problem on local network.

                        SSH maybe then, PowerShell can use encryption with some effort.