Icon

How to Duplicate and Adapt Administration Building Blocks for Custom Applications

Learn step-by-step how to duplicate, adapt, and rename administration building blocks for different applications, including best practices for managing tags and avoiding errors in your simulation environment.

By Wilbert de Witte

In this guide, we'll learn how to duplicate and adapt an administration building block for a new use case. The goal is to reuse an existing setup, make changes such as renaming and updating tags, and ensure that each application is correctly identified in the simulation.

We will also look at how to avoid confusion and errors by updating all relevant tags and restoring the original application when needed.

Let's get started

Okay. This instruction is to manually duplicate and adapt those. The issue here is that we have a specific administration building block we want to reuse, but not exactly as it is.

1
Click here
Step #1: Click here
2
Double-click on "SC depot"
Step #2: Double-click on "SC depot"

We want to adapt it and rename it. If we open the building block, we see a large list of resolved applications—hundreds of them.

3
Click on "▸"
Step #3: Click on "▸"
4
Click on "‣ ❤❤ dissolved"
Step #4: Click on "‣ ❤❤ dissolved"
5
Drag here
Step #5: Drag here

We want to do something similar, but with fewer applications and for a different molecule. We cannot multi-select and remove most of them. Instead, we duplicated this building block and removed the entire group. We have saved, for example, application one.

6
Click on "Application_1"
Step #6: Click on "Application_1"
7
Right-click on "Application_1"
Step #7: Right-click on "Application_1"
8
Click on "Save As PKML"
Step #8: Click on "Save As PKML"

Saved it as application one.

9
Click here
Step #9: Click here

Add extra comments to help differentiate it from others. We have duplicated this building block by creating a new event group and loading this event twice.

10
Type "_repeat"
11
Click on "Save"
Step #11: Click on "Save"
12
Click here
Step #12: Click here
13
Double-click on "SC depot"
Step #13: Double-click on "SC depot"
14
Click on "▸ Administrations"
Step #14: Click on "▸ Administrations"
15
Click here
Step #15: Click here
16
Click on "Application_1"
Step #16: Click on "Application_1"

Here, we have renamed it to Application Two.

17
Step #17:
18
Click here
Step #18: Click here

We have updated the relative container paths.

19
Click on "ProtocolSchemaItem"
Step #19: Click on "ProtocolSchemaItem"

We have adjusted application two here, and also here.

20
Click on "Dissolved"
Step #20: Click on "Dissolved"

Now, if we look at this in the simulation, there is a problem.

21
Click here
Step #21: Click here

The problem is as follows.

22
Double-click on "hepcludex SC reimplementation"
Step #22: Double-click on "hepcludex SC reimplementation"

If we open the building block we created with events, application one looks fine.

23
Click on "▸"
Step #23: Click on "▸"
24
Click on "▸ Administrations"
Step #24: Click on "▸ Administrations"
25
Click on "▸"
Step #25: Click on "▸"
26
Click on "Administrations"
Step #26: Click on "Administrations"
27
Click on "Administrations SC"
Step #27: Click on "Administrations SC"
28
Click on "Application_1"
Step #28: Click on "Application_1"

Application two is not correct. In the list of tags, we see "application" and "application root," which is good, but "application one" also appears.

That should be application two. So far, there has been no impact because this application is named "application two." All administration transports use relative parameters and are only active during the application. It all seems to work out fine. I think this could cause errors or at least confusion.

We want to change this. If we look at the building block, it's not something we can change directly.

29
Click on ":"
Step #29: Click on ":"

In application two, no tags are visible. This application does have a tag. It's only a problem because we can't change it. There is a way to solve this.

30
Right-click on "Application_2"
Step #30: Right-click on "Application_2"

First, we will remove the problematic simulation or application.

31
Click on "Delete"
Step #31: Click on "Delete"

We'll remove it. Yes.

32
Click on "Yes"
Step #32: Click on "Yes"

Now, we are going to rename this.

33
Right-click on "Application_1"
Step #33: Right-click on "Application_1"
34
Click on "Rename"
Step #34: Click on "Rename"

Rename it to Application Two.

Now we see a screen where we can update many tags.

35
Click on "OK"
Step #35: Click on "OK"

Also, invisible tags. Previously, we could only change three tags and the name, for a total of four items. But here, there is much more. The first step is to tag application one to application two. This is for application one. That is the one we find most important.

Of course, we want to update all of them to prevent confusion and errors. All right, now click OK.

36
Click on "OK"
Step #36: Click on "OK"

Now it's renamed. We can load our old application.

37
Click on "SC"
Step #37: Click on "SC"
38
Right-click on "SC"
Step #38: Right-click on "SC"
39
Click on "Load Application"
Step #39: Click on "Load Application"

Load the application.

40
Click here
Step #40: Click here
41
Right-click on "SC"
Step #41: Right-click on "SC"
42
Click on "Load Application"
Step #42: Click on "Load Application"

Application one, repeat.

43
Click on "Application_1_repeat"
Step #43: Click on "Application_1_repeat"
44
Click on "Open"
Step #44: Click on "Open"

Now we have our old application back.

45
Click here
Step #45: Click here

That still has all the old tags.

46
Click on "Dissolved"
Step #46: Click on "Dissolved"

We cannot do it the other way around.

47
Click here
Step #47: Click here
48
Click here
Step #48: Click here

We cannot load application two directly.

49
Click on "SC"
Step #49: Click on "SC"
50
Right-click on "SC"
Step #50: Right-click on "SC"

We can do that, of course. If we do it, we can rename it.

51
Click on "Load Application"
Step #51: Click on "Load Application"
52
Click on "Application_1_repeat"
Step #52: Click on "Application_1_repeat"
53
Click on "Open"
Step #53: Click on "Open"
54
Click on "Please enter a new name"
Step #54: Click on "Please enter a new name"

We can say three.

55
Click on "Please enter a new name"
Step #55: Click on "Please enter a new name"

The problem is that we have to manually update these tags. This is manageable, but it still requires some work. more problematic is that we cant update the invisible tags. See video for an illustration of what does not work.

For our application two, everything is done automatically.

We don't have to do any of that manually.

If we update our simulation using the building blocks, you can see that application one has the correct tag, application two has the correct tag.

In summary, what we need to to is: First, save the application, than rename (i.e. renumber) it. Then, upload the old application again. We have our two different applications.