This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. {{ :logo_guidebook1.jpg?400 |}} \\ =====LESSON 12: Updating, importing and publishing a local submodel on Dinamica EGO ===== \\ \\ ==== What will you learn? ==== * How to update a submodel\\ * How to importe an submodel\\ * How to publish an submodel\\ \\ \\ ===== Updating Local Submodels ===== At any time, the user can add or remove inputs and outputs or even change the combination of functors defining the submodel. The [[model_presentation#functor_action_bar|functor action bar]] of all functors contained inside a submodel script exhibits additional options for "exporting functor inputs and outputs". Exporting a new input or output can be performed following the steps below: First, click on the functor whose inputs or outputs will be exported. Select the "export functor inputs and outputs" on the [[model_presentation#functor_action_bar|functor action bar]] and choose the input or outputs that will be exported. It is possible to define the input and output names and their corresponding descriptions. It is also possible to mark an exported input as advanced or optional. Optional inputs can also define an optional value that will be assigned to the port if no explicit value is provided. Choose the "Submodel Options" submenu on the model toolbar and then click on "Apply Changes / Edit Submodel Properties". That brings the submodel editor dialog where you can define a new name, description and icon for the submodel or reorder its inputs and outputs (or even remove some of them). Clicking "Ok" propagates the changes to all parts of your model (and dependent submodels) where the submodel is used. Below you can see two examples of updating the inputs and output ports of a local submodel. Example 1) {{ youtube>i6T9GGqfU80?size=853x480&rel=0 |Updating local submodels ports }} Example 2) {{ youtube>FK5xIYCS0KI?size=853x480&rel=0 |Updating local submodels ports (additional approach) }} Beware that connected inputs cannot be exported. They must be disconnected first. It is also worth noting that it is possible to safely rename inputs and outputs. The connections to the port will be maintained when the changes are propagated. <note tip>Tip: Dinamica EGO comes with a set of icons from the [[http://www.fatcow.com/free-icons|Fat Cow Icon Set]] that can be used to customize the local submodels created by users. The icons come in size 16x16 and 32x32 pixels. The overall color of the icon choosen is automatically used to define the color of the functor representing the submodel on the graphical interface. The set of icons are usually installed in the folder ''IconSamples'' in your Dinamica EGO installation folder</note> When updating a local submodel, the changes from all dependent local submodels will also be propagated. It means that updating a submodel always updates the whole chain of local submodels that uses that submodel as part of their definition. {{ youtube>wDtyrRbUNo4?size=853x480&rel=0 |Updating local submodels }} Removing ports from a local submodel is also similar to updating the exported ports. You can remove the ports using "export functor inputs and outputs" option on the [[model_presentation#functor_action_bar|functor action bar]] and unchecking the corresponding port on the "Exported Ports" dialog or using the "Apply Changes / Edit Submodel Properties" dialog. Changing the order of the inputs or output ports can only be done by editing the port list on the "Apply Changes / Edit Submodel Properties" dialog. {{ youtube>zx6moYBS3YU?size=853x480&rel=0 |Removing portos and changing port order }}