How to get current file path?

Jeffrey
Posts: 2
Joined: Sat Mar 24, 2012 3:49 am

How to get current file path?

Post by Jeffrey » Sat Mar 24, 2012 4:00 am

Hi There,

I'm trying to add a new menu for DocBook5. How can I get current file path from API? Looks like AuthorAccess doesn't have related function. Thanks.

- Jeffrey

Radu
Posts: 7592
Joined: Fri Jul 09, 2004 5:18 pm

Re: How to get current file path?

Post by Radu » Mon Mar 26, 2012 10:19 am

Hi Jeffrey,

The method you are looking for is this one:

Code: Select all

AuthorAccess authorAccess = ...;
URL currentEditorLocation = authorAccess.getEditorAccess().getEditorLocation()
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Jeffrey
Posts: 2
Joined: Sat Mar 24, 2012 3:49 am

Re: How to get current file path?

Post by Jeffrey » Mon Mar 26, 2012 9:07 pm

Great, I will give a try then. Thanks.

Post Reply