Guides/Auto Open

From J Wiki
Jump to navigation Jump to search

This page describes how to configure Windows so that right-clicking a J script file (*.ijs) in Windows Explorer will give you the following options:

  • Open : starts j.exe, creates a new ijx session and opens the script file
  • load  : starts j.exe, creates a new ijx session and loads the script file in it
  • run   : starts j.exe and loads the script file without a session window

In addition, for Window 7 and Vista, the appropriate Registry entries are provided so that preview pane in Windows Explorer can display the contents of script files.


Windows XP

If you have followed the Windows XP instructions for registering .ijs files, then all you need to do is add a couple of other actions to the J Script File file type.

Jao win.png

Different command line syntax options are as follows:

    • Start j.exe, create an ijx session and open the J Script File:

"C:\progra~1\j601\j.exe" -js "open '%1'"

    • Start j.exe, create an ijx session and load the J Script File:

"C:\progra~1\j601\j.exe" "%1"

    • Start j.exe and load the J Script File without a session window. A'la Auto Start:

"C:\progra~1\j601\j.exe" -jijx "%1"

The names you give the actions are a matter of personal preference. Ditto for which action you decide to make the default (i.e. the action that will be used when you double-click on the file).

Now when you right click on an .ijs file in Explorer, you should have the options to run, load or open it.

Windows 7 & Vista

Unfortunately Microsoft have removed the GUI method of associating custom actions with file types in Windows 7 and Vista, so to accomplish the same thing requires manipulating the Registry. You could do that manually or alternatively you can download and Merge the .reg file below into your Registry (right-click on the file in Windows Explorer and choose Merge).


In addition the last two paragraphs of the .reg file below enable the contents of .ijs scripts to be displayed in the Window 7/ Vista Explorer Preview Pane. This can be a very useful way of browsing the contents of scripts.

The .reg file below assumes that you have installed J.602 in C:\Program Files\ (a system install), if you have installed J to different location you will need to edit the paths in the registerIJSfiles.reg file to point to the location of your j.exe file before you Merge it to your Registry.

Obviously all the standard warnings about backing up your Registry etc beforehand probably apply here. [{{#file: "registerIJSfiles.reg"}} Download script: registerIJSfiles.reg ]

Windows Registry Editor Version 5.00


@="J Script File"



@="\"C:\\program files\\j602\\bin\\j.exe\" -js \"open '%1'\""


@="\"C:\\program files\\j602\\bin\\j.exe\" \"%1\""


@="\"C:\\program files\\j602\\bin\\j.exe\" -jijx \"%1\""



Nota Bene

Each script you "open" will start a new copy of J.exe. If you are aware of a way to open several scripts using the same copy of J.exe, please add that information here.

See Also

  • The Guides/Auto Start page describes how to automatically run J scripts from your file or web browser.
  • The original forum thread that prompted this page
  • The forum post describing the preview pane support for .ijs files.
  • Article describing the method for adding preview support of other file types.