new FunctionList.xml item doesn't work in Administrator mode



  • I added this to FunctionList.xml:

     <parser
    			displayName="CSS"
    			id         ="css_class"
    			commentExpr="(?s:/\*.*?\*/)"
    		>
    			<function
    				mainExpr="[\.\#\w:,-\h]*\s?\{?"
    			>
    				<!--
    				<functionName>
    					<nameExpr expr="[.\w]+([.\w\:, \-]+)?" />
    				</functionName>
    				-->
    			</function>
    		</parser>
    

    If I restart N++ it works, but if I start in Adminstrator mode it doesn’t appear in the FunctionList. Strangely, all the other FunctionList items appear to work whether in normal or Administrator mode. Any ideas why this doesn’t work?



  • @Horace-Bischoff
    Yes, FunctionList.xml is in the %AppData% folder, so it shouldn’t be unavailable by running as Administrator. It’s not your changes, I’d say it’s a bug in NotePad++. I have seen the same behavior in Windows 1803 and NP++ 7.5.9



  • @Peter-Brand said:

    I’d say it’s a bug in NotePad++

    No, it’s not a bug, it works as intended.

    @Horace-Bischoff
    There are two versions of FunctionList.xml on your machine. One is stored in the user profile under %AppData%. This is the one that is specific to every user.

    The other FunctionList.xml ist stored under %ProgramFiles%. Its intended use is to provide a template of this file when Notepad++ is started under a user account which e.g. has been created after installation of Notepad++.

    What happend at your site seems to be the following: You changed the file under %AppData% but when you start Notepad+ under the administrative account this files gets not loaded. Instead the file under %ProgramFiles% is copied to the user profile of the administrative account, this is the file Notepad++ uses thereafter.

    You could copy the changes you made in FunctionList.xml to the version of the file under %ProgramFiles% but this file will be overwritten at next update of Notepad++. Thus you should copy your changes to the file under the user profile of the administrative account.



  • @dinkumoil is correct. You could also try installing NotePad++ in local mode where all the files are stored in the application’s folder and %appdata% is not used.


Log in to reply