6,685587
Grand MasterGrand Master
6,685587

    Re: Open file in New UE Window

    Sep 10, 2006#16

    I have a new solution for opening a file in new UE window without changing the setting for Allow multiple instances and if you have the INI not in program directory of UltraEdit also without a second INI. This solution is better because you can have 2 instances and both uses the same INI with identical settings.

    I have got this idea while solving a multiple instance problem - see the last two posts at Multiple instances won't disable

    Although this was bad for bjawnie, it could be also used on purpose. You could create a second UltraEdit program directory which have to contain only following files:

    dbghelp.dll
    SftpDLL.dll
    tidylib.dll
    ucl.chm
    ucl.exe
    ucres.dll

    uedit32.chm
    uedit32.exe
    uedit32.reg
    uedos32.exe
    ueres.dll

    The 3 UltraCompare Lite have to be copied only when not working with UltraCompare Professional or never use File - Compare Files from the second instance of UltraEdit.

    Second setup an user tool which runs this copy of uedit32.exe with the different program path and the current file. Because it uses the same uedit32.ini if it is not in the main UltraEdit program directory, the file is opened with a new instance of UltraEdit but uses the same INI file. If you create the environment variable UEINIDIR and set it to the correct directory, it will even work with the INI file in the main UltraEdit program directory.

    Unfortunately this method to open the current file in a second instance although Allow Multiple Instances is not checked works only for the first file. When running the tool again to open a second file also in the already existing second instance of UltraEdit, it will not work because the second file will be nevertheless opened always in the first instance. So if further files should be opened in the second instance, they must be opened from within the second instance or by drag & drop to the second instance.

    What a pity that opening more than 1 file via command line in an already opened second instance of UltraEdit is not working. That would be really cool, because some file extensions could be registered with the alternate uedit32.exe and double clicking on these files would open the files always in the second/alternate instance while all other files are always opened in the first/main instance.

    By the way: Just creating a copy of uedit32.exe in the same directory with a different name is not really better. You would need also a second set of uedit32.* configuration files (ini, kbd, mnu, pmu, tbr)  in the prefered INI directory because the default name uedit32.* for the configuration file names is exactly the name of the EXE. And an unchecked Allow Multiple Instances in the alternate INI file would cause the same effect as a second uedit32.exe in a different program path: only the first file is opened in the alternate/second instance and all other files are nevertheless opened in the first/main instance.
    Best regards from an UC/UE/UES for Windows user from Austria

    Read more posts (-14 remaining)