Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

Hi there, its been a while since I have posted any questions so I am not 100% where to post this, but it does pertain to Layouts so I will try here:

Upon creation of a new record I want to be able to generate a different Auto Entry (either Yes or No, preferably in a Radio Button) in the same field depending on which layout the user is in. Can this be done easily? Simply? Please let me know some ideas.

thanks!

Posted

What criteria determines which layout they are in and can you use that to set the radio button? Get (LayoutName) is a function that might help.

Posted

Case( get( layoutname ) = "layout 1" ; "Yes" ; "No" )

Posted

Hi Sean,

I would worry if that layout name changes. Even when I've sworn not to change a layout name because it is hard-coded somewhere, later I have forgotten and changed it and the script or calculation will break. It is best to find out the underlying reasoning on why the User is on one layout or the other and code by that reasoning instead.

What is the difference between the two layouts? Is one used only by certain privilege set? Is data in the record different in any other way? How does being on one layout differ from the other in its purpose, since obviously both layouts apply to the same table occurrence? And how do you create new records? Maybe you can use script parameter of 'A' on button on one layout and 'B' on the other and then auto-enter (do not replace) as:

Case ( Get ( ScriptParameter ) = "A" ; "Yes" ; "No" )

It would be best to base the decision on evaluating something dynamic. Just a thought. If you MUST hard-code it, list that information in your Developer section where you review things when working, so you remember it.

Posted

Thanks LaRetta (and Vaughn), both replies answered what I needed to hear.

As for avoiding using the Layout name, this is a good idea and I understand completely why one would suggest I go this way with it. I will play around with finding an appropriate way to achieve the result I want. In either case, I think the Case (Get (----)='A';'B';'C')) is the calculation I am looking for.

cheers

Posted

The other thing you can do if you must hard-code the layout name is place a text object on the layout which provides the script, calculation or value list name where it is hard-coded, something like: "Developer: layout name is hard-coded. If you change the layout name be sure to change it in 'bla bla' calculation also." Use conditional formatting of Formula = Get ( WindowMode ) < 4 and set the text to custom size 500 (more options button) so it will disappear except in layout mode.

Of course a Developer might change the name directly in Manage Layouts and never see the layout itself so it won't always protect but it helps. I would still list it in my Developer notes as backup protection.

Posted

Bingo! Another I did once was to end my layouts with -D for dummy ... no, hahah , for Developer - saying 'don't change it'. But it wasn't documented and another developer thought it meant delete, LOL. :-/

Posted

I wonder how the process knows which layout to go to... is there a field that has a value (say "quote") that indicates layout A is used, otherwise go to layout B (which is for invoices)?

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