Bookmark Destination's Location throws invalid cast exception
General-Purpose PDF Library for Java and .NET
Status: Beta
Brought to you by:
stechio
Hi,
When I try to get Bookmark's Location object, property throws invalid cast exception.
So I changed all (float)double value casts with Convert.ToSingle function in Destination.cs and my problem resolved.
Like:
case ModeEnum.XYZ:
return new PointF(
Convert.ToSingle(PdfSimpleObject<object>.GetValue(BaseDataObject[2], Double.NaN)),
Convert.ToSingle(PdfSimpleObject<object>.GetValue(BaseDataObject[3], Double.NaN))
);
Fixed on 0.1.2-Fix branch (rev 155) and 0.2.0 trunk (rev 156)
thank you