简体   繁体   中英

Opening the code file which in the HTML file and go to the given line number

I have a XSl file which reads an XML file and create an HTML file.

In the HTML file there are some links which refer to some files and a number line of the file(all file are codes). I would like to know that how can I write a code in Javascript so that by clicking in the link opens the file in Notepad++ and shows the line which is referred by the number.

For example let's I have the following link:

C:\test\test.py (42)

Then by clicking in the link I would like to ope the above file and go to the line number 42.

Thanks to @Jaromanda. Here is the answer:

C:\Program Files (x86)\Notepad++\notepad++.exe" C:\test\test.py -n42

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM