Replacing a Component

From Flowcode Help
Jump to navigationJump to search

The Component Replace function allows you to replace an existing component with another component with similar functionality, when replacing a component the properties are kept and copied over to the new component, e.g. the port and pin the component is connected to and even properties such as the Polarity etc.

There is also an option to 'Preserve current scale' which can be ticked to keep the size / scale of the component, this is especially useful when modifying and expanding existing programs so that the position and size of the component remain the same to adapt into the program as the position of the component is kept the same by default.


To replace a component, right-click on a selected component on either the 2D panels or 3D system panel and then select 'Replace' option in the context menu. This brings up the 'Component Replacement' window which contains a list of components to choose from to replace the component. This list consists of recently used components as well as components with similar functionality to adequately replace the selected component. There will be times when the required replacement component won't be shown. For example, the LED Mono is currently used and you want to replace it with an LED that will use your own images. There are a lot of LED Mono macros to replace so it would be a lot quicker to use the replace option. In this case, there are no alternative components as the 'Replace' option is grayed out.

Component-Replace1.png

All you do is add the component you want replacing, then delete it, so Flowcode remembers it.

Component-Replace2.png

Now the replace option is no longer greyed out so you can select the LED user images.

Component-Replace3.png

Finally, you might want to change the component title name as that will remain as the original components name, by clicking on the name next to Handle.

Component-Replace4.png