DrawText() and Commas  
       
      Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
        Category:  For Users of the Library
       Forum Name:  I need help - I can help
       Forum Description:  Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
       URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=2940
       Printed Date: 04 Nov 25 at 4:30AM Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com
      
 
  
      Topic: DrawText() and Commas
       
      Posted By: davbrat
       Subject: DrawText() and Commas
       Date Posted: 21 Jul 14 at 9:10PM
       
      
        
          
	
Hello all, I just started playing with the library and I have run into this while using DrawText()...
  I have a string that contains a comma inside it, which causes the string NOT to be drawn when using DrawText(). If the comma is removed, the string is drawn.
  What would cause this?
  Thanks
  Dave 
          | 
         
        
      
 
  Replies: 
       
      Posted By: Paul
       
      Date Posted: 22 Jul 14 at 9:37AM
       
      
        
          
	
Hi Dave, 
  please post your code snippet, let us see where should be the problem.
  Pal 
          | 
         
        
        
       
      
      Posted By: davbrat
       
      Date Posted: 22 Jul 14 at 6:00PM
       
      
        
          
	
Hello Paul,
  I found the problem,. I'm using Clarion 9.1 and the COM control.
  In Clarion strings are wrapped in single quotes.  So in my PDF form class...
      SELF.FillBox_C3('Fresno, CA 93721') !The form's box C3 would be filled with 'Fresno, CA 93721' 
  later I would call my DrawText() Method wrapper and passed it the X,Y & Value parameters...        Result = PDF_Container{'DrawText('& pX &','& pY &','& pValue &')'}            
 
 
  Which
 would result in the text not displaying on the form. But I found I 
needed to wrap the text string with double quotes and now all is working
 fine.
  Changed it to... Result = PDF_Container{'DrawText('& pX &','& pY &',"'& pValue &'")'}             Now the pValue is wrapped when passed to the COM control.
  It
 seems that most methods work with the single quoted strings,while 
others may choke. So I've went back to my base class and made sure all 
passed strings are now wrapped in double quotes.
 
  Thanks,
 
  Dave
          | 
         
        
        
       
      
     |