I noticed that you use == for String comparison.
Using == to compare Strings is generally not recommended.
The == operator compares the String object identities, not the String 
contents.

String one = "test";
String two = new String("test");
String three = OtherClass.makeString("t","e","s","t"); // Let's pretend 
this creates a string "test".

one == two     // This is false.
one == three   // The result is dependent on the JVM.

Unless you know exactly what you are doing (you need to know all about 
String internalization),
you want to use equals() to compare Strings:

one.equals(two)  // This is true
one.equals(three) // This is true

Note that a NullPointerException will be thrown if the left String 
object is null.
"test".equals(someStringVariable)  // This is false if 
someStringVariable is null.
someStringVariable.equals("test")  // This throws a NullPointerException 
if someStringVariable is null

/Klas
>> if (sText == "Visit Index ")
>> sText = PrintPageNo("IDX ", iPageNumber);
>> if (sText == "Chronological Visit Summary ")
>> sText = PrintPageNo("VSM ", iPageNumber);
>> if (sText == "Billing Summary ")
>> sText = PrintPageNo("BSM", iPageNumber);
>> }
>> //if(sText=="")
>>     


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions: 
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/

Reply via email to