</BUG>
TopComponent topActive = TopComponent.getRegistry().getActivated();
Node[]nodes  = topActive.getActivatedNodes();
if(nodes.length==1){
DataObject dataObj=nodes[0].getLookup().lookup(DataObject.class);
<BUG>return (dataObj!=null)?getPathFromDataObject(dataObj):null;
</BUG>
}else{
return null;
}

return FileUtil.toFile(root).getAbsolutePath();
} catch (Exception e) {
return null;
}
}
public static String getFileFromSelectedNode(boolean isFolder){
TopComponent topActive = TopComponent.getRegistry().getActivated();
Node[]nodes  = topActive.getActivatedNodes();
if(nodes.length==1){
DataObject dataObj=nodes[0].getLookup().lookup(DataObject.class);
return (dataObj!=null)?getPathFromDataObject(dataObj,isFolder):null;
}else{
return null;
