Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > General Discussion
  New Posts New Posts RSS Feed - How to Get Current Measurement Units
  FAQ FAQ  Forum Search   Register Register  Login Login

How to Get Current Measurement Units

 Post Reply Post Reply
Author
Message
jabaltie View Drop Down
Senior Member
Senior Member
Avatar

Joined: 08 Nov 05
Location: Brazil
Status: Offline
Points: 138
Post Options Post Options   Thanks (0) Thanks(0)   Quote jabaltie Quote  Post ReplyReply Direct Link To This Post Topic: How to Get Current Measurement Units
    Posted: 20 Jan 06 at 8:29AM
I'd like to retrieve Current Measurement Units but I've seen that there is no function "GetMeasurementUnits".

Why is that ? Is it really missing or there is another way to get such value ?

Back to Top
StanMarshall View Drop Down
Beginner
Beginner


Joined: 11 Jan 06
Location: United States
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote StanMarshall Quote  Post ReplyReply Direct Link To This Post Posted: 20 Jan 06 at 6:02PM

hmmm...it does seem strange that there is no GetMeasurementUnits, but there definitely doesn't seem to be.

One idea might be to set the paper size and then get the PageWidth and/or PageHeight. For example, if you set the paper size to letter and PageWidth is 8.5, you know it the current measurement units is inches. If it is 612, you know it is in points. If it is 215.9, you know it is millimeters.

(I'm not sure if these values work out exactly...the specified width in millimeters of letter sized page might be 216. You could maybe test for a range or something to be safe.)

I've never actually tried this, but I think it would work.

Good luck!

Stan

 

Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 21 Jan 06 at 7:44AM
Hi!

I don't think that's a problem.
Why you want to know such things?
The answer: You want to know it to control if it's okay...
The set-function is small and don't need performance - so set the measurement-units you need and that's it ;-)

Best regards,
Ingo
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 3524
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 21 Jan 06 at 7:45AM
I forgot:
You can't find this value inside the document. I think it's a helping value for the functions you're using after setmeasure...
Best regards,
Ingo
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store