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.

Is there a variable that holds the current user...???

Featured Replies

I do most of my scripting with ASP and just populate fields back in filemaker at the end. To fire these scripts I attach it to a button that simply uses Open URL and attaches any values from Filemaker I need as querystrings to the URL.

Is there a variable for current user I can use to also attach the current user's name as a querystring value with the URL?

Any info would be greatly appreciated. Thanks!

get(accountname)

You're in FM right? And you're sending FM data in the URL to your ASP pages, correct? Then that should work.

As an aside: are you using the old ASP or ASP.NET?

  • Author

Classic (old) ASP

  • Author

That actually returned the username that I've logged into Filemaker with, which in this case is admin. What I need is the value of User name that you put into the Preferences in Filemaker. Right now my actual name is there. That's the value I need.

  • Author

so, duh! I try Get(UserName) and that works great. Thanks!

a username is stored in the windows registry.

The following is a windows script that sets the username for filemaker 8 (will need to be adjusted for other versions) Just copy the following text to any text editer and save as "yourfilename.vbs".

Set WshShell = WScript.CreateObject("WScript.Shell")

WshShell.RegWrite ("HKEY_CURRENT_USERSoftwareFileMakerFileMaker Pro8.0PreferencesUser Name"),WScript.Arguments(0),"REG_SZ"

WshShell.Popup "Your Username has been set to " + WScript.Arguments(0),10

this can be run from filemaker using a send event.

Do it by calculation where the calulation is:

"C:yourpathyourfilename.vbs " & Quote (FieldValue or Variable you define)

this will set the username to whatever you define but filemaker will not reconize the change until the next time filemaker is opened.

Edited by Guest

this will set the username to whatever you define but filemaker will not reconize the change until the next time filemaker is opened.

2 ways around that:

- make a similar VBscript part of the Windodws logon script. instead of taking an argument, have it read the current Windows user name. (This is great for Terminal Services deployments for instance)

or

- make a pseudo filemaker shortcut that actually launches a VBscript instead of FM. The VBscript reads the Windows user name, writes it to the registry and then launches filemaker

Create an account or sign in to comment

Important Information

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

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.