?
Solved

ABCPDF 6.0/7.0 Rect Object - How to determine if any text inside a fixed size rectangle has been truncated.

Posted on 2009-06-30
2
Medium Priority
?
1,393 Views
Last Modified: 2012-05-07
Hi, I am wanting to determine if all of a long string content that I am loading into a fixed size rect object will be visible.

'I have this sub
Sub PDFAddHTML(ByVal sHTML As String, ByVal oPos As Position)
        oDoc.TopDown = True
        oDoc.Rect.String = oPos.Left & " " & oPos.Top + oPos.Height & " " & oPos.Left + oPos.Width & " " & oPos.Top
        oDoc.AddHtml(sHTML)
End Sub
 
'I would like to convert the sub into a function like below.
Function PDFAddHTML(ByVal sHTML As String, ByVal oPos As Position) as boolean
        oDoc.TopDown = True
        oDoc.Rect.String = oPos.Left & " " & oPos.Top + oPos.Height & " " & oPos.Left + oPos.Width & " " & oPos.Top
        oDoc.AddHtml(sHTML)
 
        'Your code here          
       'Return True where there is no truncation in the Rect object
       'Return False where there is truncation in the Rect object
 
End Function

Open in new window

0
Comment
Question by:mildurait
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 8

Expert Comment

by:lharrispv
ID: 24745541
just do an If Then to check to see if the length of the string is less then width of the rectangle.
0
 
LVL 11

Accepted Solution

by:
mildurait earned 0 total points
ID: 24746053
Thanks lharrispv

i found the solution...
oDoc.GetInfo(ObjectID,"Truncated")
This returns 1 if truncated else 0
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question