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

press script only once


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

Recommended Posts

hi 

i would like to know if this is possible.

i have a solution  which works in stage , first one completes stage one and if he wishes to continue he takes his stage one to stage two by creating a new record in stage two and autocompleting via variables in a script.

however i do not want one should be able to create the same stage one again to stage two, thererfore i want that once a script has run once it should become inactive and display different text, is this possible through scripting?

 

please can someone let me know there comments.

 

thanks.

or if someone has a different method that it shouldn`t be able to create a duplicate would be greatly appreciated.

Link to comment
Share on other sites

Sure it's possible. But what's a "stage" -- i.e., what makes a stage unique?

And where does the "different text" get displayed? On a button?

Link to comment
Share on other sites

Thanks Fitch.

yes i want that once the stage two record was created already it should say on the button something like "Stage 2 Created" and maybe a button near it should come up that should take me to the related record

The stages are diffrent tables

there are stages 1-4 

each one getting more detailed.

a project has to qualify first everything of stage one in order to be able to go onto stage two.

so on so forth

Edited by H
Link to comment
Share on other sites

Your data structure is still a mystery. A stage is a table? You mean a record? As in, four records, each in a different table? And they're related to a single parent record in a 5th table, which is what the layout's based on, and that's where you want the button?

You could just put your buttons in portals. That way they'd only appear when a related record exists.

Or you could use the "Hide object when" option on the Data tab of the Inspector, and a calculation like:

IsEmpty( relatedStage2::ID )

Link to comment
Share on other sites

Hi i  appreciate you trying to help me.

it is not exactly how you explain it.

my solution is as follows.

the company recieves alot of projects.

stage one is the projects basic info what it is and for whom.

if the company decides to continue with the project they would convert it to stage two where they would have to investigate various angles ie legal, finance and get various reponse on it.

stage 3 is if they actually took on the project - all its  progress etc.

the way i created it , i created a table for stage 1 with all the field it needs.

then for stage two again all those field which are necessary and more which are required.

i created a button on stage one layout which if my client wants to take his project from stage one to two it creates him a new stage two record and autofills through variables all the info from stage 1 .

what i want is that one should not be able to create a stage 2 if one has already been created.

how would i do that.

i would appreciate if somone can help me.

Link to comment
Share on other sites

1 hour ago, H said:

if my client wants to take his project from stage one to two it creates him a new stage two record and autofills through variables all the info from stage 1 .

I don't think that's a good arrangement to have. You should not have to duplicate data from "stage1" to "stage 2". And you should have a table where each project has one, unique record - no matter in which stage it is.

I would suggest you put the additional fields that are unique to "stage 2" projects in a separate Stage2 table, and define a one-to-one relationship between the Projects table and the Stage2 table. If you allow creation of records in Stage2 via this relationship, then users will be able to move a project to stage 2 just by filling one of those fields.

 

Link to comment
Share on other sites

thanks for your response.

i get what you are saying but it is important for me to be able to see in lists all projects which are in stage 1 and then all projects which reached stage 2. only aprrox 1/20 projects reach stage 2. 

what i want if their is a possibility to change the buttons appearance once it has once been activated.

Do you understand what i mean?

Link to comment
Share on other sites

2 minutes ago, H said:

but it is important for me to be able to see in lists all projects which are in stage 1 and then all projects which reached stage 2.

Where is the "but" part? You can see a list view of all projects in the Projects table, with an indicator showing which ones have a related record in the Stage2 table. And you can perform a find to show only those that have or those that don't. And you can also show a list view of the Stage2 table. Still no need for a button or replicating data.

Link to comment
Share on other sites

Correct is how would you advise me bringing in the data from Stage 1 to stage 2, i need to show the information on both records

Link to comment
Share on other sites

34 minutes ago, H said:

how would you advise me bringing in the data from Stage 1 to stage 2,

I would advise you to not bring the data from Stage 1 to Stage 2.

 

35 minutes ago, H said:

i need to show the information on both records

Show the data from the related record in the other table.

Link to comment
Share on other sites

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