Getting Started Using OpenDX

2.1 The Open Dialog Box
Let's first learn how to use the DX File Open dialog box, which is very similar to the DX File Save dialog. You'll encounter these dialogs often as you use DX. The standard file open dialog looks like this:

 

Sample DX program

To get one on your screen, hit the Samples… button and you'll be prompted to find a sample program to run.

The top line labeled "Filter" is designed to let you specify a subset of files you'd like to see displayed under the Files column on the right. This dialog uses the "*" wildcard character to stand for "any number of characters". So in my example illustration, the filter is going to look for "*.net", i.e., any and all files ending in the characters ".net" in the directory "/afs/theory.tc.cornell.edu/user/tc/chrisp" (my home directory). Since we see no files listed, that means there are no ".net" files in my home directory. That's because I'm neat and tidy and don't store them there.

The left-hand column lists all the subdirectories found under the current Filter directory. I can scroll down on the left-hand list until I locate a directory that I think has ".net" files in it, then do one of three things to modify the Filter setting:

  • click once on the desired directory and hit the "Filter" button in the bottom center
  • double-click the name of the desired directory to load it into the Filter text entry at the top
  • text-edit the Filter text directly by clicking and typing or backspacing and hitting enter

 

Double-clicking can be a problem for some people on some systems, since it must be done very quickly; it is a shortcut for the "power user". If you have trouble, use one of the other techniques.

The next image shows the result of my choosing my /dx subdirectory.

 

/dx subdirectory

The Files column auto-resizes itself to show the full extent of the longest name in the list. You can also drag on the side or corners of this dialog to make it wider or narrower to suit your taste.

At this point, I can make a selection of any one of the ".net" files displayed. Double-clicking the name of a net file will first load it into the Selection text entry box, and then will immediately open the net file. Alternatively, you can click once, then hit Open, or you could type the name yourself in the Selection text box at the bottom of the dialog. If you enter a filename by typing, be sure you leave the proper path in that box as well: just append the filename to the end of the path (after the slash). A common mistake is to edit the Filter text, then wonder why you get a "can't find file" error from DX when you hit the OK button…quot;you need to enter the desired file in the Selection text box!

Here's a tip: the Open dialog box will default to showing you the directory you were in when you launched DX. So, if you have a certain directory that contains the net file(s) for a project you are working on, navigate to that directory first, then start opendx, then use the Open command. This saves time setting the Filter to get to the desired directory. The same is true for Save: by default, the file you save will be saved in the directory you launched DX from, unless you change the output location within the Save dialog. So if you plan to work on files and save files into a particular project directory, go to the directory before launching DX.

 

When switching between projects, I find it faster to quit DX, move to the new project directory and relaunch than to spend a lot of time fiddling around with the Open and Save dialogs.

There's another important feature to note about how the Open and Save dialogs work. If you opened a file while I was talking, you are now in DX, so choose Open… from the File menu and do not save when prompted. If you did not attempt to open a file, you should still be looking at the Open dialog box.

The first two entries in the left-hand directory column will always end in "." and "..". Unix users already know why but for everyone's sake, I'll explain. In Unix, the "." directory is the current directory ("you are here"). The ".." directory is the directory one level up from the current directory (relatively speaking). All the other named directories you see in the directory list are one lower than the current directory. The current directory (in absolute path terms) is listed on the Filter line at the top, that is, everything up to the final "/" on that line is where you are.

 

Optional: View this Technical Aside if you want more detail on this subject; the information is not required to understand the upcoming material.

Often, you want to go up one or more directories from where you currently are. To do so, simply double-click the ".." entry. If you are not having success double-clicking, you can hand-delete the last subdirectory from the Filter text entry. For example, if the Filter is currently "/u/mydir/dx/*.net", changing it to read "/u/mydir/*.net" will take you up one level. And as before, since ".." is like an alias for the directory one level up, you can simply click once on the ".." entry, then hit the Filter button to move up one more directory.

As should be obvious to almost anyone who uses a computer with a graphic user interface, the Cancel button lets you bail out of this dialog without changing or opening anything.