Jump to content

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

Recommended Posts

Posted

Greetings,

So I have multiple Container Fields and I want to create a script that can be used on those multiple Container Fields instead of creating each script for each Container Field. I have a simple working "Insert PDF script" below:

 

Go to Object [Object Name: "Container1"]

Insert PDF []

 

But of course the problem is that if I have 20 Container fields I will have to write each script for each Container field. Not to mention the Delete PDF Script.

 

So I tried the Set Trigger Script on Object Enter and it works fine when I click the Container Field I am able to insert a PDF but the problem is that the script will run regardless of the Container field is Empty or Not Empty and I only want it to run only if the Container field is empty.

 

How Can I accomplish this?

Posted
31 minutes ago, emtau said:

I only want it to run only if the Container field is empty.

That's not possible - but you could branch your script using:

If [ IsEmpty ( Get (ActiveFieldContents ) ) ]
   # do something
Else
   # do something else
End If

However, the UI you're building is non-standard, and you might want to reconsider your entire approach. Especially since you say you might have 20 container fields. It sounds like you should have 20 related records instead, with a single container field each.

 

  • Like 1
  • Thanks 1
Posted

Thank you Very much.

You right I might over exaggerate the number of Container Fields, but I'll take your point into consideration in the future.

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