About the usage of GetAnnotPropertiesValues in javascript API

Discussions about DocuVieware integration in GdPicture.NET.
Post Reply
kelvinn
Posts: 2
Joined: Thu Oct 25, 2018 5:39 am

About the usage of GetAnnotPropertiesValues in javascript API

Post by kelvinn » Thu Oct 25, 2018 6:02 am

I am trying to get the (left, top, height, and width) properties from a newly created rectangle annotation object. As far as my understanding, the GetAnnotPropertiesValues method is the best way to do that. I followed the instruction here: https://www.docuvieware.com/guides/aspn ... alues.html
Below is the function I made:
function getAnnotationValue() {
var result = DocuViewareAPI.GetAnnotPropertiesValues("DocuVieware1", 1);
if (result == 1)// 1 if error
{
alert("error");
}
else {
alert(result);
}
}
I build it and yet nothing happens, not even an error alert. And even I try some testing code e.g. (alert ("hello")) at the end of the function it still shows nothing. Please suggest a correct method for the implementation of this method if I am wrong. Thank you.

kelvinn
Posts: 2
Joined: Thu Oct 25, 2018 5:39 am

Re: About the usage of GetAnnotPropertiesValues in javascript API

Post by kelvinn » Tue Nov 06, 2018 5:29 am

Any sign of solution?

User avatar
Loïc
Site Admin
Posts: 5653
Joined: Tue Oct 17, 2006 10:48 pm
Location: France
Contact:

Re: About the usage of GetAnnotPropertiesValues in javascript API

Post by Loïc » Mon Jan 14, 2019 6:18 pm

Hello Kelvin,

Sorry for the delayed answer.

I've tested your code, it works fine, at least with our latest release. You should try to update.

Also I think you may want to replace:

alert(result); <- this line should display [object]

by

alert(JSON.stringify(result));

Please let us know if your problem persists.

With best regards,

Loïc Carrère

Post Reply

Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot] and 1 guest