It's done. It's in the CVS in AcroFields.java. 

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Paulo Soares
> Sent: Tuesday, July 05, 2005 6:36 PM
> To: R K
> Cc: [email protected]
> Subject: RE: [iText-questions] checkbox becomes invisible
> 
> I'll have a solution this week. 
> 
> > -----Original Message-----
> > From: R K [mailto:[EMAIL PROTECTED] 
> > Sent: Tuesday, July 05, 2005 5:02 PM
> > To: Paulo Soares
> > Cc: [email protected]
> > Subject: Re: [iText-questions] checkbox becomes invisible
> > 
> > Is there any work around with the checkboxes, because these 
> are built
> > in templates which I am planning to reuse while moving to iText.
> > 
> > 
> > On 7/5/05, Paulo Soares <[EMAIL PROTECTED]> wrote:
> > > Now I got it. Those two checkboxes should be radio boxes. 
> > What you have
> > > is two checkboxes with the same name but with different set 
> > names. When
> > > iText sets a name it does it in both boxes but as only one 
> > of them has
> > > the right appearance the other gets no appearance. Maybe it 
> > should show
> > > the Off appearance when no set state could be found.
> > > 
> > > > -----Original Message-----
> > > > From: R K [mailto:[EMAIL PROTECTED]
> > > > Sent: Tuesday, July 05, 2005 4:00 PM
> > > > To: Paulo Soares
> > > > Subject: Re: [iText-questions] checkbox becomes invisible
> > > >
> > > > I have tried the getAppearanceStates().
> > > > if(key.indexOf("ValPaymentTerm") > 0){
> > > >    String[] arr = form.getAppearanceStates(key);
> > > >    for(int i=0;i<arr.length;i++){
> > > >       System.out.println("states"+i+"::"+arr[i]);
> > > >    }
> > > >    form.setField(key,"Collect");
> > > > }
> > > >
> > > > But after setting the Collect value the other checkbox becomes
> > > > invisible. How to make it visible?
> > > > These are the states I am getting from that checkboxes :
> > > > states0::Prepaid
> > > > states1::Off
> > > > states2::Collect
> > > >
> > > > Regards
> > > > RK
> > > >
> > > > On 7/5/05, Paulo Soares <[EMAIL PROTECTED]> wrote:
> > > > > There's no problem with the files and iText. The problem is
> > > > that only
> > > > > one field has the set value of "Collect", the others have
> > > > the value of
> > > > > "Prepaid". To know what value to set call
> > > > > AcroFields.getAppearanceStates().
> > > > >
> > > > > > -----Original Message-----
> > > > > > From: R K [mailto:[EMAIL PROTECTED]
> > > > > > Sent: Tuesday, July 05, 2005 3:21 PM
> > > > > > To: Paulo Soares
> > > > > > Subject: Re: [iText-questions] checkbox becomes invisible
> > > > > >
> > > > > > Thanks for the immediate response.
> > > > > > Please find the orginal pdf attached.
> > > > > >
> > > > > > Regards
> > > > > > RK
> > > > > >
> > > > > > On 7/5/05, Paulo Soares <[EMAIL PROTECTED]> wrote:
> > > > > > > I need the original PDF.
> > > > > > >
> > > > > > > > -----Original Message-----
> > > > > > > > From: R K [mailto:[EMAIL PROTECTED]
> > > > > > > > Sent: Tuesday, July 05, 2005 2:33 PM
> > > > > > > > To: Paulo Soares
> > > > > > > > Subject: Re: [iText-questions] checkbox becomes 
> invisible
> > > > > > > >
> > > > > > > > Please find the pdf attached.
> > > > > > > > In that WT/VAL section, PPD should come without 
> the check
> > > > > > as I have
> > > > > > > > pre populated the other one.
> > > > > > > >
> > > > > > > > Thanks
> > > > > > > > RK
> > > > > > > >
> > > > > > > > On 7/3/05, Paulo Soares <[EMAIL PROTECTED]> wrote:
> > > > > > > > > Post also the PDF.
> > > > > > > > >
> > > > > > > > > ----- Original Message -----
> > > > > > > > > From: "R K" <[EMAIL PROTECTED]>
> > > > > > > > > To: <[email protected]>
> > > > > > > > > Sent: Friday, July 01, 2005 9:26 PM
> > > > > > > > > Subject: [iText-questions] checkbox becomes invisible
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > Hi,
> > > > > > > > >
> > > > > > > > > I have a form which contains checkbox groups.
> > > > > > > > > If I tried to prepopulate the checkbox using
> > > > PdfStamper, only
> > > > > > > > > prepopulated one will show up in the form and 
> the other
> > > > > > one which is
> > > > > > > > > part of the checkbox group will become invisible.
> > > > > > > > >
> > > > > > > > > If I didnt populate the checkbox fields, both of them
> > > > > > get displayed.
> > > > > > > > >
> > > > > > > > > Please find the piece of code below.
> > > > > > > > >
> > > > > > > > > PdfReader reader = new
> > > > > > PdfReader("D:\\itext\\checkboxgroup.pdf");
> > > > > > > > > PdfStamper stamp = new PdfStamper(reader, new
> > > > > > > > > FileOutputStream("D:\\itext\\GO_NEW.pdf"));
> > > > > > > > >
> > > > > > > > 
> > stamp.setEncryption(true,null,null,PdfWriter.AllowFillIn|PdfWr
> > > > > > > > iter.AllowPrin
> > > > > > > > > ting);
> > > > > > > > > AcroFields form = stamp.getAcroFields();
> > > > > > > > > Iterator it = form.getFields().keySet().iterator();
> > > > > > > > > while(it.hasNext()){
> > > > > > > > >      String key = (String)it.next();
> > > > > > > > >        pagesize =
> > > > reader.getPageSizeWithRotation(1).height();
> > > > > > > > >    if(key.indexOf("Address") > 0){
> > > > > > > > >    String sAddress = "abc\nwest side 
> dr\ngaithersburg";
> > > > > > > > >    form.setField(key,sAddress);
> > > > > > > > >    }
> > > > > > > > > else if(key.indexOf("ValPaymentTerm") > 0){
> > > > > > > > >               System.out.println("Setting check box
> > > > value ");
> > > > > > > > >                   form.setField(key,"Collect");
> > > > > > > > >
> > > > > > > > >        }
> > > > > > > > >        counter++;
> > > > > > > > >        }
> > > > > > > > > stamp.close();
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > Regards
> > > > > > > > > RK
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > 
> -------------------------------------------------------
> > > > > > > > > SF.Net email is sponsored by: Discover Easy 
> > Linux Migration
> > > > > > > > Strategies
> > > > > > > > > from IBM. Find simple to follow Roadmaps,
> > > > > > straightforward articles,
> > > > > > > > > informative Webcasts and more! Get everything you need
> > > > > > to get up to
> > > > > > > > > speed, fast.
> > > > http://ads.osdn.com/?ad_idt77&alloc_id492&op=ick
> > > > > > > > > _______________________________________________
> > > > > > > > > iText-questions mailing list
> > > > > > > > > [email protected]
> > > > > > > > > 
> > https://lists.sourceforge.net/lists/listinfo/itext-questions
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > > > -------------------------------------------------------
> > > > > SF.Net email is sponsored by: Discover Easy Linux Migration
> > > > Strategies
> > > > > from IBM. Find simple to follow Roadmaps, 
> > straightforward articles,
> > > > > informative Webcasts and more! Get everything you need 
> > to get up to
> > > > > speed, fast. 
> http://ads.osdn.com/?ad_idt77&alloc_id492&opclick
> > > > > _______________________________________________
> > > > > iText-questions mailing list
> > > > > [email protected]
> > > > > https://lists.sourceforge.net/lists/listinfo/itext-questions
> > > > >
> > > >
> > >
> > 
> 
> 
> -------------------------------------------------------
> SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
> from IBM. Find simple to follow Roadmaps, straightforward articles,
> informative Webcasts and more! Get everything you need to get up to
> speed, fast. http://ads.osdn.com/?ad_idt77&alloc_id492&op=ick
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> 


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_idt77&alloc_id492&op=click
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to