Jump to content
Server Maintenance This Week. ×

variable - appending data? displaying data?


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

Recommended Posts

A couple of variable questions:

1: I am trying to build a running list of actions completed by the user in a variable that will later be inserted into an email. I have a variable pulling data, but how do I "stack" the data? I have a loop built, but it seems to be overwriting not adding.

the variable is $mfgrel_list

the line in the loop is:

set variable [$mfgrel_list; value:$mfgrel_list & ¶

The hope was that it would append the data by grabbing the existing variable data first, then adding the current record data to it.

2: What is the best way to view this variable in a layout? I would like to have a "status" window that displays this stacked variable data to the user as they are working. I placed it in a text within a merge field, and also tried a text field with a calculation to the variable, but neither worked.

thanks,

Link to comment
Share on other sites

That is almost correct.

set variable [$mfgrel_list; value:$mfgrel_list & ¶ & YourField ]

To view the variable data, you can set the value into a field ( global field if you want to see the same across all records )

Link to comment
Share on other sites

How would the auto-enter work in this case? It all depends on when the action is taking place. You should just set the field after your loop is done with a Set Field [ YourField; $mfgrel_list ]

Link to comment
Share on other sites

well, (my error) the auto-enter didn't work because I was using the wrong thing. thanks for the fix.

OK, now the data is showing, but back to question one. It is not adding to the variable, it is overwriting it with the new data. How do I get it to add or stack data?

Link to comment
Share on other sites

I thought I already responded to that...

You script should look something like this.

Loop

Set Variable [ $mfgrel_list; value:$mfgrel_list & ¶ & YourField ]

Go to Record [ Next; Exit after last ]

End Loop

Set Field [ YourField; $mfgrel_list ]

Link to comment
Share on other sites

Got it. I had it set up as a global variable ($$xxxx) so it would last from step to step, but when I called for it in the stack step, it was calling a simple variable ($xxxx).

Thanks so much for your help.

have a great weekend.

Link to comment
Share on other sites

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