Most Frequent Mistakes

to be more clear:

If You are in the field-definitions, do some changes in one or more fields, hit escape - then a dialog appears, asking if You wan’t to discard the changes.

If there are similar (cf…) ‘elements’ where after the same operation that dialog does not appear, then I treat it as a bug.

2 Likes

Fair 'nuf. It’s funny how we get used to having to work around oddities like that over time. My downstairs bathroom door had a crappy doorknob for a while that required major torque to open. Now we’ve replaced it and fixed the “bug”, and I’m still gripping that thing like the Hulk had too much coffee. I’ll probably end up breaking the handle again with my learned behavior and end up back where we started.

2 Likes

or a more filemaker-one:

With macOS 10.14 and the new USBC Mini, every now and then the bluetooth connection will get lost for mouse&keyboard

We have to plug the magic keyboard (plug the mouse will not help), use ‘tab’ a few times until the mouse-sign appears (‘connection lost’), the turn mouse off, on - after a few seconds, every thing is fine again.

After this is solved (maybe in 2020), if the mouse-battery drains empty, we will connect the keyboard (etc.)…

habits :crazy_face:

‘Habits’ a good subject for another thread. LOL. We use ‘command shift M’ on our systems that allows a developer to install the standard FileMaker menus on our systems.

So before going to layout mode, script workspace, etc. it is always ‘command shift M’. Every time I work on someone else’s systems, I still habitually use the keyboard combination.

4 Likes

IIRC, on one of the last solutions I worked on, there was a custom menu set installed for general users.

In that custom menu set, I added two menu items which would only be visible/available for full access accounts:

  1. Enter To Layout Mode
  2. Open Script Workspace

These used the same standard keystroke commands that are normally associated with such actions.

I mapped them to a script which first installed the standard FileMaker menu set, after which the desired action would be performed (open script workspace, layout mode).

This allowed me to use my standard FMP keystroke habits, but kept me out of the pitfall of using them without effect.

EDIT: I just had a flashback to this system and realized that I think the script actually only installed the standard menuset, thus requiring me to repeat the keystroke command. I can not recall if there was a reason why I did not have it do both commands, or if it just did not occur to me at the time.

‘Habits’ a good subject for another thread. LOL. We use ‘command shift M’ on our systems that allows a developer to install the standard FileMaker menus on our systems.

So before going to layout mode, script workspace, etc. it is always ‘command shift M’. Every time I work on someone else’s systems, I still habitually use the keyboard combination.

1 Like

Yesterday I stumbled upon something, I hadn’t been aware of:

I used GetAsNumber to parse some data from content like “risk level high (2.0)” into a numerical value. Since I had to translate to a different schema for calculation I added a simple Case(value = 1, 1;value = 1,5;2;value = 2;3;"") but I got no result.
Hmm, so after thoughts about wrong context, wrong field, no input values I put it to the dataviewer and guess what: I got negative values from GetAsNumber.
Since I did all this in FM16 I looked at the FM-Help and found nothing. I looked it up in the FM-18-Help and there it is stated:
GetAsNumber ( "-22" ) and GetAsNumber ( "(22)" ) return -22 .

GetAsNumber(“you were to fast (more than 34km/h)”) of course returns -34

So that was new not only to me and but also to the FM-Help - while this behaviour already existed in FM 11 (tested yesterday) and maybe even earlier.

something for the weekend
Holger

5 Likes

(some_number) is used by accountants to display negative numbers in some financial reports. It’s known to some of us - I know accounting also. Thing is you learned that FileMaker get this, (some_number), as a number.

One way to prevent this would be to add a parameter to state if “()” are considered part of a number or not - should that happen that may be looooooooooong. The fastest way would be to filter out ( and ) before using GetAsNumber.

1 Like

for this special case I use Abs(GetAsNumber(…)) but I was a bit suprised to find this in the first place :slight_smile:

1 Like

I manage it to define script-parameters in the define-button (by copy/paste) window - and then not to save that. Every now and then, a script will not work as expected because I lost the script-param’

It's a bit late to reply but I'm a fan of the touchbar. It does so much more than a single row of function keys.

Expecting the Replace Field Contents command to create new records across a relationship.

Was it ever possible to create new records in a related table by using Replace Field Contents to set data in the field? The fact that the Replace Field Contents currently only sets data in existing records doesn't stop me from trying to do this.

About once a year when I'm hacking data sets I try to save the time it takes to write a looping script by placing the calculation into a Replace Field Contents. Yesterday, it only took me a few minutes to spot the error, but I've probably lost more time than I've ever saved.

4 Likes

Don't know why I have not mentioned this one earlier:

forgetting to make sure a newly defined calculation field outputs the calc to the correct type (text, number, date, ...)

I've stopped counting how many times I dismiss the dialog and need to go back because I overlooked making a selection from the type drop-down.

7 Likes

These have been fun to read!

The one I'm most embarrassed about is forgetting to enable scroll bars on portals. I've been iteratively developing new layouts with some users, and more than a few times I've completely left out a needed scroll bar. The next time we work on it there will be several revisions along the lines of "Many of the rows were missing". :man_facepalming:

3 Likes

The one I laugh at myself about most was when working through a new script, I had placed an Exit Script as the first step, to make sure it didn't run before I was finished, and couldn't be accidentally run. So I could manually step past that with the debugger.

Well, short story, a week later, when the feature I added wasn't working ... it took me about 10 mins figure out why.

6 Likes

Lots of trouble can be caused by NOT checking only one of the 3 checkboxes...or so I have heard :wink:

image

1 Like

Every now and then I still carelessly make this mistake...

4 Likes

not taking a break to enjoy the win, after solving a complex or 'doh!' issue.

8 Likes

... My most frequent typo when specifying cURL Options calc in Insert from URL script step:

-H \"Content-Type: applicaiton/json\"

...instead of the correct spelling of:

-H \"Content-Type: application/json\"

... no end of frazzlement in trying to work out why an API call isn't working because of it!

4 Likes

Have you tried apps like text expander and other keyboard related utilities? You could define that pattern and have the app swap it for the correct spelling.

Unless you need to type 'applicaiton' somewhere else? Just saying... it could be the last time you see that one problem.

3 Likes

I'd go one step further and have it replace a code phrase with the whole line.

Something like:
.apjs
becomes
-H "Content-Type: application/json"

5 Likes