Jump to content

how to repeat a script automatically


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

Recommended Posts

Hi all! I am trying to find a way to repeat a perform script 800 times and I cannot do that manually; I went up to 60 records, but that was it. The script has to do with the creation of new records. I would be grateful for any advice

Many thanks

Link to comment
Share on other sites

Try something like:

Loop

Set Variable [ $i; $i + 1 ]

Exit Loop If [ $i > 800 ]

New Record

End Loop

many thanks for the suggestion. My script is the following and it would be great if you could tell me where to accommodate the above :B

Go to Layout ["physics_only"(physics_only)]

New Record/Request

If [all_physics::item_id ≠ IsEmpty (physics_only::item_id)]

Perform Script ["item-phys"]

End If

Link to comment
Share on other sites

the general context is that I want to create a new record in a specific layout (physics_only) and if field item_id is empty in another layout, then script item-phys automatically enters text 'physics' into the field item_id of physics_only layout. does it make any sense? and at the end I would like to create 800 such new records.

Link to comment
Share on other sites

does it make any sense?

Not to me, I am afraid.

if field item_id is empty in another layout

A field is never empty in a layout. It is empty in a record*. If that record is in another table, then the only way to find out if it is empty is through a relationship. Since the current record is new and its fields are empty, it cannot have related records anywhere.

---

(*) with the exception of global fields

Link to comment
Share on other sites

:B ok, this gets very complicated for me. I agree, I am talking about two different tables. but the script currently works the way it is. what I would now like is to repeat this script 800 times so that I can create these new records.

Link to comment
Share on other sites

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