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.

error in custom function

Featured Replies

I am trying to install a custom function from http://www.briandunning.com and can't see why I am getting an error message.  

The message is "An operator (e.g. +,-, *, …) is expected here."

 

The function is :

Let(

[NumbersOnly = Filter(Phone; "0123456789");
NewNumber = Right(NumbersOnly; Length(NumbersOnly) - 1);
NewFormat = Right(Format; Length(Format) - 1)];

Case(

not IsEmpty(Format);

Case(
Left(Format; 1) = "#";
Left(NumbersOnly; 1) & PhoneFormat(NewNumber; NewFormat);
Left(Format; 1) & PhoneFormat(NumbersOnly; NewFormat)
)

)

)

The error occurs on the opening parentheses here "PhoneFormat(NewNumber;)"

 

I have this same function working perfectly on another file and can't see why I getting this error on the file I'm working on.

 

Can someone point me in the right direction?

The setup works.. make sure the Function Name is right. this is recursive function that calls itself so the name has to match

 

here is the recursive call... Left(NumbersOnly; 1) & PhoneFormat(NewNumber; NewFormat);

 

The Function Name match the bold underline italic

 

I have this same function working perfectly on another file and can't see why I getting this error on the file I'm working on.

 

Can someone point me in the right direction?

You do know that with FileMake Pro Advance, you can Copy a Custom Function in one file and Paste it into another, right?

  • Author

Thanks very much for you replies.  When I saw "make sure the Function Name is right. this is recursive function that calls itself so the name has to match", I thought of course.  But then I went and tested it again and this time it worked with a different Function Name than in the function.  So I resolved the problem but not my understanding of it.

I also realised after posting that in Advanced not only can you copy and paste functions but you can import them directly from another file. 

Thanks for all that.

But then I went and tested it again and this time it worked with a different Function Name than in the function.  So I resolved the problem but not my understanding of it.

 

Yes, I think by now you have increased the overall level of confusion considerably. Would it be possible to see a screenshot of your original attempt, with the error message?

 

I also realised after posting that in Advanced not only can you copy and paste functions but you can import them directly from another file. 

 

and a Utility such as Clip Manager 4

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.