Community
    • Login

    File association and language association

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    style configlanguageassociations
    2 Posts 2 Posters 3.7k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J. Andrew SmithJ
      J. Andrew Smith
      last edited by

      How do I go into Preferences / File Association and actually associate an extension with Notepad++? And how can I tell Notepad++ that certain extensions should be associated with a certain language?

      Here’s my context: I do a lot of VBA coding, and I export VBA code quite often into files with extensions BAS, CLS or FRM. I’d like Notepad++ to come up whenever I double-click such a file in Windows Explorer, and I’d like it to automatically know that the language is “Visual Basic” (or is it “VB/VBS”? I’ve seen both). I’d also like to double-click on any TXT, LOG, INI or INF file and have Notepad++ open it as a Normal Text file. I can’t do any of these.

      File Associations: I go into Prefs / FA’s, I click “Notepad”, then I double-click “.txt” and “.log” so they both end up on the rightmost list, under “Registered extensions”. I do the same in “ms inf/ini” with “.inf” and “.ini”. Then I click “customize” and add “,bas”, “.cls” and “.frm”. Doesn’t that mean all these extensions are registered such that, if I double-click a file with any of these extensions in Windows Explorer, the file should open in Notepad++? Doesn’t happen. Doesn’t work.

      Language Associations: where and how do you tell Notepad++ that BAS, CLS and FRM files are “Visual Basic”-language files?

      Style Configurator: it seems I can also associate “bas”, “cls” and “frm” with the “VB/VBS” language. Do I really have to do two tasks for every file association like this?

      1 Reply Last reply Reply Quote 0
      • YvesMPY
        YvesMP
        last edited by

        Hi,
        menu and choice name will not be accurate in my answer because I’m not on an English installation, but I guess it will be close enough
        to open all files with a given extension with Notepad++ by double click, right click on such a file in the file explorer, choose properties, and select Notepad++ as the application for opening (you might need to give the full path to the binary).
        To tell Notepad++ to apply a language to an extension, go to menu list Parameters, choose Syntax coloration, select the target language in the panel, and type your extension in the fields on the bottom (on my install only two choices). And then of course save and apply.

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        The Community of users of the Notepad++ text editor.
        Powered by NodeBB | Contributors