Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Launch Ping command

Featured Replies

I am trying to figure out a way to automatically launch the ping command built into Windows and automatically put in the address to ping from a field within the FM database. I managed to have the script launch a command prompt window by using the send event command. I think the next step would be to use the Send DDE Execute command, but I do not know what to put in the Topic field of that script step. Does anyone know if this is possible?

Thanks in advance for any help you can provide.

You can try something like this.

Send Event ["avet"; "odoc"; "cmd /c ping " & gIPfield & " > C:/Pingresult.txt"

Then import the C:/Pingresult.txt file into a FileMaker field to view the results.

Hmm, kind of weird that Windows accepts a forward slash as a valid path in the cmd console.

Actually it is not. DOS has always recognized forward slash as parameter. Example: Dir /p will list the directory contents and the parameter /p pauses after each screen display.

Edited by Guest

righto, sorry, never used dos lol :P

And besides, i said it was odd that it accepted it in a file path... never said anything about the parameters.

... But after googling a bit it turns out file paths are interchangeable in windows i.e. OR / .. but what really happens is that the / are converted to ... any who.

Edited by Guest

  • Author

You can try something like this.

Send Event ["avet"; "odoc"; "cmd /c ping " & gIPfield & " > C:/Pingresult.txt"

Then import the C:/Pingresult.txt file into a FileMaker field to view the results.

Thanks for the reply. I do not need to have the results in a Filemaker field, only ping an IP address in a Filemaker field viewing the results in the ping window. Is there a way that can be done using the command you posted?

Thanks.

Send Event ["avet"; "odoc"; "cmd /k ping " & gIPfield]

  • Author

Is that supposed to go into the calculation function of Send Event?

yes. with gIPfield being the field in FM that stores the IP address.

  • Author

Ok, I tried it, but it will not accept it. Are all parameters correct short of the field name? I assume to remove the "Send Event" part of that calculation as FM would look for a table called Send Event. Pardon my ignorance in using this script step as I have never used it before.

Thanks for all your help.

Send Event is a script step (represented by the fact that it is enclosed in square brackets).

Go To Scripts -> ScriptMaker.

Make a new Script call it Ping or something.

Look for the script step called "Send Event".

Click Specify once you've added the step to your script.

Choose calculation and click specify.

the only part that goes into the calculation is: "cmd /k ping " & gIPfield

  • Author

That works great. Thanks everyone for your help.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.