Jump 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.

How to do this on Windows?

Featured Replies

Hi:

I am not that familiar with automation tools on Windows.

So here is a brief explanation of how I automate this task on the MacIntosh.

I read the contents of a folder of PDF files and then write the returned string to a text file. That file is then imported into filemaker.

Here is the Applescript/Shell Command that reads the file.

set theFolderList to do shell script "ls '/Volumes/main/Business/ADD/Export/'".

How would I achieve the same on the Windows side.

Thanks in advance

2 different methods you can use: a command line or a VBscript. A VBscript requires more code but has also more power. I've included a script below. There are however a couple of hoops you have to jump through to use the VBscript approach.

Let's stick with the command line approach:

cmd /c dir /b c:theFolder >c:outputfile.txt

You use the Send Event script step to execute this.

Anatomy:

"cmd /c" calls the Windows command line interperter and tells it to quit when done with the command ("/c")

"dir /b" tells Windows to produce a list of files, but just the names no other info ("/b")

">c:outputfile.text" tells Windows not to show the list on the screen but to redirect the output to a text file

-------------------------------------------

Set sh = CreateObject ("Shell.Application")

Set oFolder = sh.Namespace ("d:downloads")

Set fso = CreateObject("Scripting.FileSystemObject")

For Each filename In oFolder.Items

filenamesstring = filenamesstring & "," & filename

Next

Set oFile = fso.CreateTextFile("c:testfile.txt", True)

oFile.WriteLine(filenamesstring)

oFile.Close

  • Author

Thanks Wim

  • 2 weeks later...

After you have the outputfile.txt, how would i get the contents of that file into a filed on my database. Using import creates seperate records. I would like to bring the entire dir list into 1 record in one field.. Is that possible?

Thanks Stu

Yep, but it takes some wizardry :

Make sure there is only one record in your found set. Import into a global, use the "update existing" option of the import.

AHHH!! Very Nice Thanks for the tip

Create an account or sign in to comment

Important Information

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

Account

Navigation

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.