Can't run the browser for all file types from the View menu



  • In View > View Current File In… > Firefox, Chrome, Edge, IE works for certain file types I tried, like .html, .cmd, .mnu.
    They are grey colored and don’t work for example in case of .txt, .ini, and others. All files are coded ASCII 1250.

    The Run - Launch in Firefox, etc, commands work fine for all file types.

    Debug infos:
    Installed:
    Notepad++ v7.7.1 (32-bit)
    Build time : Jun 16 2019 - 21:14:50
    Path : C:\Program Files (x86)\Notepad++\notepad++.exe
    Admin mode : OFF
    Local Conf mode : OFF
    OS : Windows 10 (64-bit)
    Plugins : combine.dll ComparePlugin.dll DSpellCheck.dll HexEditor.dll LocationNavigate.dll mimeTools.dll NppBookmarkManager.dll NppCalc.dll NppConverter.dll NppExport.dll NppSaveAsAdmin.dll PluginManager.dll

    local:
    Notepad++ v7.7.1 (32-bit)
    Build time : Jun 16 2019 - 21:14:50
    Path : D:\Soft\Notepad++P\notepad++.exe
    Admin mode : OFF
    Local Conf mode : ON
    OS : Windows 10 (64-bit)
    Plugins : Combine.dll ComparePlugin.dll DSpellCheck.dll HexEditor.dll LocationNavigate.dll mimeTools.dll NppBookmarkManager.dll NppCalc.dll NppConverter.dll NppExport.dll NppSaveAsAdmin.dll PluginManager.dll



  • Indeed.

    See issue#5903 for a request to fix that. Feel free to comment on / upvote that issue to try to get it more traction.



  • It is working for me. Am I missing something?

    Screenshot



  • It may depend on a preference or side effect, for example file association, language, highlighting , etc



  • The Build times are different
    My Build time is : Jun 16 2019 - 21:14:50,
    downloaded at 2019. 06. 20.
    My OS is Windows 10 (64-bit)

    SinghRajenM’s Build time is Sep 1 2019
    Both is v7.7.1 (32-bit).



  • @Laszlo-Botka That is my dev build. Even I can see with release version as well -

    Screenshot



  • I get the same result, if run the freshly unzipped npp, everything is default.

    Imgur



  • As I had the same results as @László-Botka had, I took the chance to see what the code looks like
    and it seems that code just checks if a file has an extension association registered other than notepad++
    and if it has, then it enables the menu items.
    So, at my machine I have assigned txt extensions to be assoc’ed with npp and if I open such a file
    the menu items are disabled. The same is true for file extensions without an association.
    But extensions like .py or .log, which aren’t assoc’ed with npp are possible to view in browsers.

    The code in question is this and that, I guess.



  • I’m sorry @Ekopalypse, I don’t understand the codes

    But I don’t really understand why the entensions should be checked: the file is open in Notepad++.

    I use only Firefox, don’t know what do other browsers.

    Firefox will handle it according to the extension, process it, play it, visualize it, save it, … or open as a simple text file, like txt cmd ini, vbs, js, even xxx, yyyy

    But this is definitely the user’s responsibility, as is what it writes into the browser’s address bar.

    At least Firefox works this way.



  • @László-Botka

    But I don’t really understand why the extensions should be checked: the file is open in Notepad++.

    I don’t know the reason why this was implemented but, as far as I understand the code,
    this is how npp decides if it should enable the menu items or not.
    Make a simple test, use one of the files with an extension you know doesn’t work.
    Assign it, let’s say to notepad (NOT NPP). Open it in npp and you should see
    that your browser menu gets enabled. At least it does for me.



  • You’re true.
    For example txt is registered in npp, and npp is the default application for txt In Windows 10, and the browser menu is disabled.
    The browser menu is enabled for inf and vbs, and default application is assigned - but not npp - for them in W 10.


Log in to reply