The following code tests to see if any of the revisions in a
document are hybrid.
bool isHybrid = false;
using (var doc = new Doc()) {
doc.Read(Server.MapPath("../mypics/sample.pdf"));
using (var eof = new ObjectSoup.Eof()) {
eof.Load(doc.ObjectSoup);
var xref = eof.XRef;
while (xref != null) {
if (xref.Type == ObjectSoup.XRefType.Hybrid) {
isHybrid = true;
break;
}
xref = xref.Prev;
}
// do something with isHybrid
}
Dim isHybrid As Boolean = False
Using doc As New Doc()
doc.Read(Server.MapPath("../mypics/sample.pdf"))
Using eof As New ObjectSoup.Eof()
eof.Load(doc.ObjectSoup)
Dim xref As ObjectSoup.XRef = eof.XRef
While xref IsNot Nothing
If xref.Type = ObjectSoup.XRefType.Hybrid Then
isHybrid = True
Exit While
End If
xref = xref.Prev
End While
End Using
' do something with isHybrid
End Using