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 5977 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Has anyone been able to use the Get(ActiveSelectionStart)function with FileMaker Pro 9.03? In theory I should be able to have two field (one being the calculation) and another a text field. When I click into the text field and highlight a selection of text I should have a number showing me my start point in the calculation field?

Posted

No, in theory you can't because the calculation field will calculate only when exit from the first field ( and then there is NO active selection )

But you can use ToolTip.

BTW: which is the need for this ?

Posted

My initial problem is I have a scrolling text field that sometimes contains more data than the field size. The user needs to highlight a portion of the text to copy it to another field, but when that happens the scrolling field jumps back to the top and the user loses his place. My thought was that if I could capture the selection start through a script then I could also set the cursor back using the Set Selection script step to the correct possition.

Posted

No need of that calculation field.

You'll need to create a button with only this step:

Set field [ anotherField ; Middle ( Get ( ActiveFieldContents ) ; Get ( ActiveSelectionStart ) ; Get ( ActiveSelectionSize ) ) ]

The user will select a text in the first field ( or even in another ) and press the button; the first field remains in focus where it was ( no more jumps back to the top ).

If you wish to copy more than a portion of the first field into the second one, change the step to:

Set field [ anotherField ; Trim ( anotherField & " " & Middle ( Get ( ActiveFieldContents ) ; Get ( ActiveSelectionStart ) ; Get ( ActiveSelectionSize ) ) ) ]

This topic is 5977 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.