# How to create new buttons?

**URL:** <https://resource.dopus.com/t/how-to-create-new-buttons/54229>\
**Category:** Help & Support\
**Created:** [January 20, 2025, 1:18pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229 "2025-01-20T13:18:34Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 20, 2025, 1:18pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/1 "2025-01-20T13:18:35Z")

</div>

I want you to help me with an issue that bothers me a lot about Opus.

There is a function in Powertoys (Microsoft app) called Folder + which copies files pre-defined by the user to another folder that the user wants to copy.

This function doesn't work in Opus, I want to know why? You can adjust it to get it, in Windows Explorer it works normally.

If it doesn't work, can you help me make a similar function within Opus' native settings?

The image below is the powertoys function I am referring to.

![image](https://resource.dopus.com/uploads/default/original/3X/2/c/2ca99e2e11efead3a5033cc0a5633f64ab2ef2a3.png)

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 20, 2025, 1:33pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/2 "2025-01-20T13:33:47Z")

</div>

> [@Prata](#):
>
> which copies files pre-defined by the user to another folder that the user wants to copy.

Can you give more detail on that? How is the folder it copies to defined?

You can almost certainly do the same thing in Opus.

> [@Prata](#):
>
> This function doesn't work in Opus, I want to know why?

It's probably only designed to work in File Explorer, but I didn't write PowerToys so I can only guess. It isn't needed within Opus anyway, and Opus's own file copying code/UI will work better anyway.

---

<div class="post-metadata">

**Author:** ![PassThePeas](https://resource.dopus.com/user_avatar/resource.dopus.com/passthepeas/32/50972_2.png) [@PassThePeas](https://resource.dopus.com/u/PassThePeas)\
**Post date:** [January 20, 2025, 1:41pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/3 "2025-01-20T13:41:43Z")

</div>

You might find the thread below of interest as it deals with the main feature of "New+" : creating folder structures from templates.

> [@Possible to create, copy, define folder structure templates?](https://resource.dopus.com/t/possible-to-create-copy-define-folder-structure-templates/53217):
>
> I am wondering if it is possible create or maybe even save multiple folder structures so that I can create a new folder with a template the user defines at the click of a toolbar button. So instead of having to go to my own custom premade folder and …

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 20, 2025, 5:50pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/4 "2025-01-20T17:50:07Z")

</div>

When I'm browsing a folder, I want to be able to copy pre-configured files to the folder I'm in using a command. That's what the powertoys function does.  
Is that clear now?

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 20, 2025, 6:04pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/5 "2025-01-20T18:04:35Z")

</div>

First, check [How to use buttons and scripts from this forum](https://resource.dopus.com/t/how-to-use-buttons-and-scripts-from-this-forum/3546/1) for how to use the commands below.

Make a button with a command like:

```plaintext
Copy "C:\My Files\File 1.txt" HERE
Copy "C:\My Files\File 2.txt" HERE
Copy "C:\My Files\File 3.txt" HERE

```

Or use wildcards in the filename to match multiple files:

```plaintext
Copy "C:\My Files\File *.txt" HERE

```

Or copy the whole folder to the current directory:

```plaintext
Copy "C:\My Files\*" HERE

```

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 21, 2025, 2:51pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/6 "2025-01-21T14:51:34Z")

</div>

It worked, now I want to automate more, because when I click on the created button a dialog box appears, is it possible to automate without opening this dialog box?

---

<div class="post-metadata">

**Author:** ![jinsight](https://resource.dopus.com/user_avatar/resource.dopus.com/jinsight/32/43666_2.png) [@jinsight](https://resource.dopus.com/u/jinsight)\
**Post date:** [January 21, 2025, 4:09pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/7 "2025-01-21T16:09:53Z")

</div>

What is the code in your created button? That code determines whether a dialog box appears.

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 21, 2025, 4:48pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/8 "2025-01-21T16:48:07Z")

</div>

Which dialog box appears?

What is your current command/code?

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 21, 2025, 5:55pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/9 "2025-01-21T17:55:42Z")

</div>

![image](https://resource.dopus.com/uploads/default/original/3X/a/c/acc7856afe3b429cdf2a1cd4c4b941696786764f.png)

 ![image](https://resource.dopus.com/uploads/default/original/3X/4/1/416aae80029c73a2b02bf21140440bcfa4d4130c.png)

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 21, 2025, 6:30pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/10 "2025-01-21T18:30:19Z")

</div>

We can't see the full command in your screenshot.

I can only guess, but I suspect you didn't include the `HERE` argument.

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 21, 2025, 6:59pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/11 "2025-01-21T18:59:05Z")

</div>

I hadn't put it exactly. I did and it worked now.

Now help me do the following:

I'm in the folder where I want to copy the files, can I pre-configure some files or folders and when I click on the command, a pop-up appears with only the files I configured and I can choose which one I'm going to copy?  
Similar to the image below

 ![image](https://resource.dopus.com/uploads/default/original/3X/1/3/1350011603fc37ff223f37489f760a871c256a9d.jpeg)

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 21, 2025, 7:17pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/12 "2025-01-21T19:17:53Z")

</div>

It's possible, but very different to what you asked for originally. More detail would also be needed to know exactly what you want. (Do you want to just copy individual files? Multi-select them? Copy all of them sometimes but not others?)

It's better to put the full detail when asking for something. Drip-feeding detail means people waste time providing solutions which then have to be thrown away for a completely different approach after more information is provided.

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 21, 2025, 7:24pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/13 "2025-01-21T19:24:06Z")

</div>

I apologize, but I don't have much programming skills yet, but I know you're right.

That's exactly what you asked, I want to have multiple files inside this pre-configured repository and sometimes I copy one or more of them.

Sorry, but I think you get the idea.

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 21, 2025, 7:25pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/14 "2025-01-21T19:25:21Z")

</div>

How was it done in New+? It looks like it just gives you a menu of files/folders that can be copied, where only one can be selected.

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 21, 2025, 7:31pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/15 "2025-01-21T19:31:59Z")

</div>

This is actually a function of Microsoft PowerToys, not made in Opus.

But this PowerToys function, when you click on it, copies the file or folder when you click on the file or folder.

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 22, 2025, 10:05pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/16 "2025-01-22T22:05:35Z")

</div>

Will you help me?

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 22, 2025, 10:22pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/17 "2025-01-22T22:22:48Z")

</div>

You can do the same thing just by making multiple menu items using the examples above.

If you want a UI where you can multi-select items, i.e. more advanced than what New+ was doing before, that is possible but would require writing a script, which I don't have time to do at the moment, sorry.

(If all the files/folders you want to be able to select are directly below the same folder, or a handful of folders, it's also possible to generate the menu items to copy them automatically, without scripting. Depends on those details, though.)

---

<div class="post-metadata">

**Author:** ![Prata](https://resource.dopus.com/user_avatar/resource.dopus.com/prata/32/64428_2.png) [@Prata](https://resource.dopus.com/u/Prata)\
**Post date:** [January 23, 2025, 1:46pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/18 "2025-01-23T13:46:11Z")

</div>

"it's also possible to generate the menu items to copy them automatically, without scripting"  
Help me do it this way, please.

---

<div class="post-metadata">

**Author:** ![Leo](https://resource.dopus.com/user_avatar/resource.dopus.com/leo/32/69732_2.png) [@Leo](https://resource.dopus.com/u/Leo)\
**Post date:** [January 23, 2025, 1:48pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/19 "2025-01-23T13:48:33Z")

</div>

> [@Dynamic menu to copy template files from folder to current location?](https://resource.dopus.com/t/dynamic-menu-to-copy-template-files-from-folder-to-current-location/38646/2):
>
> We'll add something to make this kind of thing easier in the next beta: The Go FOLDERCONTENT command, which generates toolbar buttons or menu items listing the items below a specified folder, has new modes which copy the clicked files into the curr…

---

<div class="post-metadata">

**Author:** ![lxp](https://resource.dopus.com/user_avatar/resource.dopus.com/lxp/32/33734_2.png) [@lxp](https://resource.dopus.com/u/lxp)\
**Post date:** [January 23, 2025, 2:04pm UTC](https://resource.dopus.com/t/how-to-create-new-buttons/54229/20 "2025-01-23T14:04:52Z")

</div>

> [@Prata](#):
>
> I want to have multiple files inside this pre-configured repository and sometimes I copy one or more of them.

That's the perfect scenario for dual-display mode.

[Next page](https://resource.dopus.com/t/how-to-create-new-buttons/54229.md?page=2)
