Using the "copy piston to clipboard" option


#1

I have multiple locations and multiple instances of WebCore. I am trying to copy some of my pistons from one instance to antoher using the copy piston to clipboard.

image

When I go to the other instance of WebCore by using the drop down on the top of the page and select create new piston there is no option to paste in the copied code. How is this feature supposed to work?


#2

That just copies the info in text format, not meant to copy piston from one instance to another. Have you tried importing the red-snapshot instead? I don’t have multii instance so I have not tried it.


#3

Have you looked at this thread? Iapaterson added this ability with one of the last releases of webcore


#4

The file back up works across instances. You just have to assign devices when you import.


#5

Yes I have used backup and restore and create new piston from existing. Just wanted clarity on this copy piston to clipboard, always looking for easier ways of doing things.

Thanks everyone.


#6

So what is the easiest way to copy a block of code from one piston to another? What if they are in two different instances?


#7
  • Select a block of code (or a single line)
  • Double check the left margin to see what is selected
  • Right click to the right of that selected block
  • Copy Selected Statement

Then, in any other piston (or instance), you can paste that block (or single line).

  • Click on “+ Add a new statement(for a block), or “+ Add a new task(for a line)
  • In the popup window, scroll down. You will see the allowable clipboard(s).
  • Click on “Paste this statement” to insert that clipboard at that cursor location

Note, if you select a single line, it can only be pasted back into a similar container.
(Certain blocks exhibit this as well)

IE: You might not be able to paste “Set Fan to Auto” into a lightbulb block


Pro Tip: Each browser keeps it’s own clipboard.


Edit:

This question has inspired me to update the Wiki / Drag & Drop.
Any future tips & tricks I think of will be updated there.


#8

This option did not come up. That was the issue.


#9

That usually means that what is on the clipboard is not compatible with the section of code you are trying to paste into. (so it won’t even appear in the clipboard list)

I know my “IE” example above was silly, but that logic applies to many other types as well.

Just for an example, depending on where I try to paste, my clipboard list will change very dramatically.
(only showing me what is allowed)


Edit:

Also, make sure you are not in an incognito or private browser, since cookies would not be set properly.


#10

Now that I have slept on it, I think you have answered this question for me before. I believe you suggested just dropping the block at the bottom and then pulling it to where you need it. Yep, that worked when I tried again this morning. Sometimes, I just beat my head against the wall…that’s how I roll sometimes. LOL


#11

Excellent!

One small note for future reference:
When it comes to single lines on a clipboard, we may have to create a new empty container (block) that will accept that single line.