Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 3523 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I"m having some strange issues with the "Get ( ActiveModifierKey )" command in Filemaker Pro 11. Users are running on Macs, all either running 10.5 or 10.6 and running FMP 11.1-11.3. I have a couple of scripts set up to take advantage of shift+clicking to pop up new windows. Every once in a while the ability to shift+click disappears. It's an extremely intermittent issue but it's a show stopper as some key workflows are access solely via this modifier key. What's even more strange is that when I log on to the users desktop via ARD and try the command, the command works! I can verify that the shift key is working correctly when this issue presents itself as the user can type in both captals and lowercase letters, but regardless Filemaker does not recognize the key is pressed.

What's even more aggravating is that the fix is not always the same. I've had users restart FMP and their entire computers to no avail, and sometimes the issue just resolves itself. This is a VERY strange issue and I'm wondering if anybody else out there is experiencing this?

Posted

I"m having some strange issues with the "Get ( ActiveModifierKey )" command in Filemaker Pro 11. Users are running on Macs, all either running 10.5 or 10.6 and running FMP 11.1-11.3. I have a couple of scripts set up to take advantage of shift+clicking to pop up new windows. Every once in a while the ability to shift+click disappears. It's an extremely intermittent issue but it's a show stopper as some key workflows are access solely via this modifier key. What's even more strange is that when I log on to the users desktop via ARD and try the command, the command works! I can verify that the shift key is working correctly when this issue presents itself as the user can type in both captals and lowercase letters, but regardless Filemaker does not recognize the key is pressed.

What's even more aggravating is that the fix is not always the same. I've had users restart FMP and their entire computers to no avail, and sometimes the issue just resolves itself. This is a VERY strange issue and I'm wondering if anybody else out there is experiencing this?

How are you checking for modifier keys?

Posted

How are you checking for modifier keys?

I'm not sure what you mean. The script itself is using the Get ( ActiveModifierKeys ) command to determine what key is pressed while the script is running.

Posted

I'm not sure what you mean. The script itself is using the Get ( ActiveModifierKeys ) command to determine what key is pressed while the script is running.

Well for instance if you test for Get ( ActiveModifierKeys ) = 1 that assumes the only modifier key depressed is one of the shift keys. However if the caps lock is activated, the result would be 3 and a test for just the shift key only (1) will fail. Remember that different combinations of modifier keys will give you a different result.

  • 1 month later...
Posted

Welp, sorry to dredge up this topic again but this issue will not go away. Yes, I am well aware different key combinations will result in the result of the Get ( ActiveModifierKeys ) calculation but I am 100% certain that this is not the root of my problems. JUST NOW I had an instance where a script I was trying to call which relies heavily on the shift key being pressed to highlight multiple selections did not work. I am 100% sure that no other modifier key was being pressed while I was running the script. When I brought up the Info Window to check if there were any other keys being pressed the Get ( ActiveModifierKeys ) came back with a result of 1, which is shift. The strange part is that after I checked the Get Info window and went back to try the script again it worked as expected.

Very annoying...........

Posted

When I brought up the Info Window

Do you mean the Data Viewer? Did you have this open while the script was running?

With intermittent behavior, I'd suspect the keyboard may be faulty. Another possibility is a timing issue: if the script lags a bit, you may be checking for the pressed keys too late. And i wouldn't dismiss what RoidSierra said, either.

Posted

Do you mean the Data Viewer? Did you have this open while the script was running?

With intermittent behavior, I'd suspect the keyboard may be faulty. Another possibility is a timing issue: if the script lags a bit, you may be checking for the pressed keys too late. And i wouldn't dismiss what RoidSierra said, either.

Ya I meant the Data Viewer. I have not yet tried running the data viewer side by side when the script is running because 99.999% of the time the script works correctly and when it doesn't, it's usually on a computer with only the FMP client installed. I'd have to rule out script timing because I've been physically present on a client OS machine when this problem happens and I have seen it with my own two eyes; no amount of shift+clicking will work until FMP is restarted. Capslock wasn't pressed and no other modifier keys were pressed as well.

When this problem first popped up I too thought that it may have been a keyboard failing and so I replaced it on the effected client computer. As this is a pretty rare error, I haven't verified that this has happened on their computer since the replacement, but it just happened on my computer and I know the keyboard isn't going out.

This isn't a show stopping error because it happens to infrequently but ******* is it annoying when it happens. I haven't been able to reproduce this in testing, either. I know FMP has some annoying bugs, and this one is right up there.

Posted

I would place a button somewhere that does nothing except show a custom dialog = Get ( ActiveModifierKeys ). Next time you get to a point where "no amount of shift+clicking will work until FMP is restarted", see what this button says . Try the same thing with another file, too - as corruption in your file cannot be ruled out. Testing a local vs. hosted file may also be helpful, in case it's a glitch in your network.

  • 3 weeks later...
Posted

Welp, it just happened again. I modified the layout on Filemaker and the associated scripting to include a global variable that displayed the results of Get ( ActiveModifierKeys ) that ran every time the user tried to run the associated script. When I tried it everything worked as expected and displayed the expected 13 for control and 1 for shift modifier keys.

When I ran the same command from the users computer the global variable displayed "0". Again, no amount of restarting FMP would fix the issue, only completely restarting solved it.

Posted

Exactly where in the script are you calling for Get ( ActiveModifierKeys ) and what is the script doing? I suggest you set a variable at the top of the script to capture the value. Also would be helpful if you actually posted your script.

Posted

The modifier key needs to be pressed at the point the check in the script is made, not at the start of the script.

<script start>

<stuff that takes 5 seconds to process>

Get( ActiveModifierKeys )

In this case the keys needs to still be pressed 5 seconds after the script started running. Hence Bruce's suggestion to remember the modifier key value at the start of the script.

  • 2 weeks later...
Posted

James, I have been searching online for any answers to this as I am having the same problem. I'm noticing it not only affects script behavior but also affects developer-accessible screens. As you stated, it's very intermittent (although I'm noticing greater frequently in 10.7 Lion). When the problem occurs, shift-click and option-click ceases to function in the following areas:

  • When calling Get ( ActiveModifierKeys )
  • When dragging objects on a layout in layout mode.
  • When dragging objects in the relationship graph.

Oddly enough, it works fine when typing letters or shift-selecting items in lists (scripts, layouts, tables, fields, etc.)

  • 3 years later...
Posted

I had this problem today. Quitting FileMaker and relaunching it did not solve the problem. 

Just to address those who think it's a scripting issue, it failed when I had a button directly running a Show Custom Dialog with Get ( ActiveModifierKeys ) displaying in the dialog - it showed 0. 

Restarting my Mac fixed the problem. Not sure how or why. 

This topic is 3523 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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