on 02-10-2009 8:29 AM
Hi experts :
Now i develop employee CV programe use adobe form, when a employee open his CV,his photo will display in PDF dynamicly.
when i use the script :this.value.image.href = xfa.resolveNode(this.value.image.href).value;When preview it these error display : Script failed (language is formcalc ;context is xfa[0].form[0].Node[0].page1[0].ImageField[0])scripts= this.value.image.href = xfa.resolveNode(this.value.image.href).value;
Error : Malformed SOM expression;
The Photo do not display in PDF form.
Can you tell me how do you do with it?
thank you
zunxian
zunxian,
Try this in Java script,
Imagefield.value.image.href =Textfield.rawValue
Textfield --- where you r getting your url.,keep this as invisible .
Thanks and Regards,
Siva
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
If you are using Interactive Forms with WDJ then you can use a Modifiable Binary type to pass the image to the PDF.
Then in the PDF script you can use the "Formatted Value" property.
Try the following code
byte[] l_companylogo = emp_table<i>.getCompanyLogo();
IWDResource l_resource = WDResourceFactory.createCachedResource
(l_companylogo,"MyImage",WDWebResourceType.JPG_IMAGE);
wdContext.currentContextElement().setCtx_va_imagebinary(l_companylogo);
Make sure you pass the l_companylogo field above to the Adobe form.
Write the follwing FormCalcscript on the "initialise" method of the Image field in the form :
M_myform.#subform[0].Subform1.ImageField1.formattedValue
Thanks,
Virag
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Virag:
Thank you and your answer.
May I ask you another question ?
These code I canu2019t understand
1.byte[] l_companylogo = emp_table<i>.getCompanyLogo();
What is 'emp_table<i>' and 'getCompanyLogo();'
2.Ctx_va_imagebinary is the pdfSource?
Now I want to display employees photos in PDF from a file system.I can get the URL with the file system.How can i do it?
Thank you a lot!
yours zunxian
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.