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.

I can't seem to get "Go To Layout (layout name by calculation)" to work ... help?

Featured Replies

I can't seem to get "Go To Layout (layout name by calculation)" to work ... help?

I'm passing a variable "$Layout" as the calucation. I've checked spelling over and over. I've tried different layouts. It simply won't honor the name in the variable. Any ideas anyone? I'm in the latest version of everything.

Steve Shiver

4 minutes ago, steveshiver said:

Any ideas anyone?

Based on what?

Hi Steve,

How about you create a simple file showing exactly how 1) you are setting that $layout script variable and 2) your Go To Layout[ by calculation] example?  Are you wrapping quotes around $layout? 🙂

Edited by LaRetta

  • Author

Well, I'm happy to provide more information; just not sure what that information would be. I'm setting a local variable "$Layout" with the value of the layout name to which I need to navigate. In this case the layout name is "PD_085". That's exactly the name of the layout. When the script step Go To Layout (layout name by calculation) executes I receive an error "105: Layout is missing". But the layout is there. This happens with every layout I try.

Any thoughts?

Steve Shiver

HI LarRetta!

I am NOT wrapping quotes around $Layout. Should I be wrapping quotes around the value that inside $Layout?

BTW (my middle name is Rhett):)

 

here's the script

sample_script.jpg

14 minutes ago, steveshiver said:

I'm happy to provide more information; just not sure what that information would be.

Information that would enable us to reproduce your problem.  LaRetta suggested an excellent way to do that. What you have provided so far is insufficient, as you can see in the attached file. Unless the file doesn't work for you - which would mean you have a problem in your system. 

Test.fmp12

  • Author

OK. Well, LaRetta got me to thinking ... "surely I wouldn't need quotes?" So I decided to try it with quotes anyway. As a result I could see in dataviewer that there was a space after the last letter of the $Layout value. So I learned the MiddleValues function included the carriage return as well as the value. I fixed with the following and now all is great! Thanks to you both.

Steve

 

sample_correction.jpg

Why not simply use the GetValue() function?

I was suggesting you NOT wrap $layout in quotes.  That would be a common mistake.  Did you view Comment's file?  I suggest you take a look.  You can drop all that extra stuff.

hahah!  We all posted simultaneously!  Don't say we aren't quick at assisting folks here on FMForums!    🙂

  • Author

Yep. I should've used the GetValue(). Thanks!

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.