Right mouse click, New -> how to edit list of options?

If I open Explorer.exe, and right mouse inside a folder, New, the options I have created show just "Text Document" or "Winrar Archive" (nothing else)

that's the way I want it.

under dopus (latest version), this same action shows also "Microsoft Access application" and "Rich Text Format" in addition to the above two items

how can I get rid of the two items (MS Access and Rich Text) in dopus, New?

I'm like you and only want three items on my New menu. However, I've put them directly on the right-click menu so I don't have to use a submenu to get to them. Makes things much faster and it's fine when there's only two items.

To do this go to Customize, Context Menus and edit the Lister Context menu. Add new items to the menu to create your desired filetypes, with commands like this:

FileType NEW=.txt
FileType NEW=.rar

I've also got a CreateFolder command on there.

Personally I like to keep the New menu there, just in case, but if you want to get rid of it you can move the Lister Context Menu item (within the Lister Context menu -- i.e. not the menu itself) into a sub-menu or delete it completely. This might take some other items with it, though, although I'm not sure which other items might appear as part of that item, other than the New menu.

You might also be able to move the New menu to somewhere else, without moving any other items that may be part of Lister Context Menu, by adding a command to a sub-menu which runs the FileType NEWMENU command, although I haven't tried this and might be wrong.

Just to expand on the Filetype NEW=".txt" command:

I find it handy to add the following arguments:

FileType NEW=.txt NEWNAME="{dlgstring|Enter filename:}"

This then creates a dialog asking for a filename. You can then override the .txt extension with anything you like. Handy for creating other text type files, like .html, .php, .cpp, etc. If you don't enter anything then Opus reverts to creating the default filename New Text Document.txt.

[quote="tanis"]Just to expand on the Filetype NEW=".txt" command:

I find it handy to add the following arguments:

FileType NEW=.txt NEWNAME="{dlgstring|Enter filename:}"[/quote]
Yes, very handy indeed. Is it possible to extend this command so that it opens the newly created text file with an editor? I tried adding a notetab {f} command but this just seems to break the FileType NEW. I freely admit to not knowing what I am doing! :wink:

Regards, AB

It's possible but a little fiddly to setup.

Firstly, you need to setup a user command to launch your editor of choice. (Setup user commands in the customize dialog. In the Commands tab there's a User category, select this then add a new command.)

In my case I'm using a program called ConTEXT and the command line for my user command is:

"C:\Program Files\ConTEXT\ConTEXT.exe" {filepath}

I named the user command Context.

Once you've done that you can create a normal opus button to create the file and call your new user command:

FILETYPE NEW=.txt NEWNAME="{dlgstring|Enter filename:}" Go Refresh Set SORTBY=modified SORTREVERSE=On Select FIRST TYPE=files dopusrt /cmd Context

The final command is launching your user command so make sure you change Context to whatever you name yours.

This fails for me because the Select FIRST TYPE=files does not work. I can consistently replicate this in an instant command (CLI) window. In a structure where the first three entries are folders...

C:\2005\current
C:\2005\archive
C:\2005\sandpit
C:\2005\20051202.xls
C:\2005\20051203.xls

Select FIRST TYPE=files always selects C:\2005\current instead of C:\2005\20051202.xls. I am running version 8.2.0.2.

Regards, AB

Seems like it doesn't work with folders so for now modify the button to:

FILETYPE NEW=.txt NEWNAME="{dlgstring|Enter filename:}" Go Refresh Set HIDEFILTERFOLDERS=* Set SORTBY=modified SORTREVERSE=On Select FIRST TYPE=files dopusrt /cmd Context

(bug report filed)

OK. Thanks. Is that a buglet in Select FIRST?

I used your code as-is in a context menu and added an extra Set HIDEFILTERFOLDERS to put things back (almost) the way they started. Very neat!

FILETYPE NEW=.txt NEWNAME="{dlgstring|Enter filename:}" Go Refresh Set HIDEFILTERFOLDERS=* Set SORTBY=modified SORTREVERSE=On Select FIRST TYPE=files dopusrt /cmd Context Set HIDEFILTERFOLDERS
Regards, AB

Wouldn't it be easier to make a button which starts the editor either with the new filename (assuming the editor allows you to give it a filename that doesn't exist yet -- TextPad does and prompts you to create the file) or with no filename but started from the directory in question (so that you can do a save or save-as and name the file then)?

But it wouldn't be half as much fun, and how else would we discover that Select FIRST TYPE=files doesn't do what one might reasonably expect? :wink:

Cheers, AB

To do this go to Customize, Context Menus and edit the Lister Context menu. Add new items to the menu to create your desired filetypes, with commands like this:

I need a little more directions here as I can open dopus, navigate to Customize, Context Menus, Lister Context but then I don't know how to make any changes

The options I have is Show, Restore, Default or if I dblClick the "Lister Context" it opens up Show but I don't know how to get rid or my original post items "MS Access.." and "Rich Text.."

how do I enter the commands and edit this? If I click on the folder open icon it opens a dialogmenu with a bunch or .dop files which contain xml commands

Well, firstly you are in the right spot... so go back into Customize->Context Menus and doubleclick on the Lister Context item. This opens the menu in edit mode so you will not see the actual New -> menu item that you'd expect... You should instead see an item called Lister Context Menu. Click the RMB on it and select Edit. A Command Editor window will open and in the Function: field you should most likely see the command:

FileType CONTEXTMENU=Directory\Background

You can edit this to append the following to the end of the function/command:

CONTEXTOPTIONS="EXCLUDE=.mdb,.rtf"

That should do it...

CONTEXTOPTIONS="EXCLUDE=.mdb,.rtf"

ok, thank you, that worked and I was able to follow the directions

splendid indeed!

now, I have one more issue:

I just ran a Photoshop session and since closing Photoshop another "new" item has automatically inserted itself into dopus,new "Adobe Photoshop Image"

how can I get rid of this and more importantly will I continuously have to battle this menu as I start new applications by dopus inserting things into "new" without asking me?

under Explorer.exe I still only have two(2) items, Text file and Winrar

ok, solved

I changed the item to

CONTEXTOPTIONS="INCLUDE=.txt,.rar"

no more nuisance items shown or they are now ignored

Bravo Anonymouse... three cheers for the online help :slight_smile:.