Skip to content

Launching from the Command Line

You can start Database Explorer with command line arguments. All command line arguments start with a dash followed by a single character (case insensitive) indicating the action to be taken. The order of the arguments (if not conflicting) does not matter. The following arguments are recognized:

Parameter Help

Pass a -h as a command line argument, and Database Explorer will show an information box with all parameters that can be passed.

Workspace Name

Passed as -x. The workspace filename may be either the SWS or the WS filename. Passing the SWS filename results in loading the WS filename from the information read in the SWS file. The full path to the filename must be given. If the workspace filename does not exist, you will be notified with help information about the possible command line flags that you can pass. After that, the last used workspace is used.

If you want to use Database Explorer without a workspace, you can pass the value NOWORKSPACE.

Samples:

c:\program files\dataflex\bin\dbexplor.exe -x "c:\program files\dataflex\examples\order entry\programs\config.ws"
c:\program files\dataflex\bin\dbexplor.exe -x NOWORKSPACE

Note that if the path contains spaces, you need to enclose the whole parameter in double quotes.

Table Number

Passing the -t plus a number (integer) results in opening the table with that number if listed in the file list. If no table with that number exists, nothing happens except starting Database Explorer itself. Passing a file number only works in conjunction with the workspace name.

Table Name

Passing the -t plus an alphanumeric value results in opening the table via OPEN AS. The name of the table must have the full path to the table if it cannot be found in the current or passed workspace. If the table cannot be opened, you will receive an error. From that point on, it is up to you to select a table from the workspace, do something else, or just terminate.

This feature can be used to assign Database Explorer as the tool to open a table from Windows Explorer. The feature works best with the embedded database, but intermediate files are supported as long as the INT file supplies all the information to open the table via OPEN AS.

Note that if the path to the table contains a space, you need to surround the whole command line argument with a set of double quotes.

Steps to Assign Database Explorer to Open a Table from Windows Explorer

  1. Open Windows Explorer.
  2. Select the Tools pulldown.
  3. Choose Folder Options.
  4. Click the File Types tab.
  5. Click the New button.
  6. Enter DAT in the File Extension form.
  7. Do not enter more and click OK.
  8. Highlight the new file type by clicking on it.
  9. Click the Advanced button.
  10. Click the New button.
  11. Enter OPEN in the action form.
  12. Enter the location to Database Explorer in the Application form. If the path contains spaces, surround the whole path with double quotes. Add after this path "-t%1". The quotes are necessary here because the filename and path may contain spaces. If you want, you can pass -x NOWORKSPACE as well.
  13. Click OK and see the new action in the list. Optionally, you can press the Set as Default button and change the icon.
  14. Click OK and close.

Now you should be able to double-click in the Windows Explorer window.

Note: The steps above apply to Windows XP Professional. Windows 2000 and earlier might do this differently. If your Windows version is not an English version, pulldowns, options, and buttons carry a different name. If the above does not work, seek support from Microsoft.