How can I get the foonote number of the current Footnote in DocumentVisitor?

How can get the foonote number of the current Footnote in DocumentVisitor?

public override VisitorAction VisitFootnoteStart(Footnote footnote)

{

footnote.?------>I need to extract the number assigned to the current footnote?

AppendText(" (VisitFootnoteStart) ");

return VisitorAction.Continue;

}

Exmple :

this is an footnote 1 and we want to exract the number 1 which represent (1 is the first note)

1) 1 is the first note

The problem is that footnote numbers are not stored in Microsoft Word documents. Footnote numbers must be calculated by the program that needs them. The same can be said about numbered paragraphs.

Aspose.Words calculates footnote numbers (and list numbers) when it needs them. E.g. when exporting or rendering. But at the moment there is no way to get these numbers programmatically from the model.

We do have this feature planned (to be able to return list and footnote numbers), hopefully some time in 2009.

In the meantime you can try calculating the number of the footntoe yourself. You can keep a counter for footnotes, You can also access document and section properties that specify footnote starting number. This all will be fairly easy. Let us know if you need a code example.

The only problem you will have is that footnote number can be one of several number styles (e.g. Arabic, Uppercase Roman, Lowercase Roman etc). But if you limit yourself to just Arabic numbers it will be easy to do.