Is it possible to generate an NRL file via the iManage API?

2.5k Views Asked by At

Using the Autonomy Interwoven products Desksite or Filesite, it is possible to drag a document out of the application onto the desktop, which creates a .NRL file.

This file contains metadata including the name of the Interwoven server, the document id, version of the document etc.

Assuming we have a reference to an existing IManage.IManDocument object, is it possible to generate one of these nrl files programmatically via the SDK?

1

There are 1 best solutions below

1
On BEST ANSWER

Sure - this is simple. Here is a basic C# function that will do just this, with the IManDocument object named aDoc:

TextWriter nrlCreator = new StreamWriter(fileName, false);
try
{
    nrlCreator.WriteLine(string.Format("{0}\n{1}",
                         aDoc.Database.Session.ServerName, aDoc.ObjectID));
    if (SLSettings.CopyLinkToLatestVersion)
    {
        nrlCreator.WriteLine("[Version]");
        nrlCreator.Write("Latest=Y");
    }
    nrlFiles.Add(fileName);
}
finally
{
    nrlCreator.Close();
}