Home
 
The page you are viewing is part of our 160,000 page PDF discussion forum archive spanning 1999-2011.
Go to the new Planet PDF forum to join the PDF community.
 

Search
 Advanced   
Sign up for a WebBoard account Archive Forum Home


PLATINUM
SPONSOR

GOLD
SPONSORS



Topic  
Go to previous topicPrev TopicGo to next topicNext Topic
Author Message
Cryotech
Cryotech

Total Messages 2

Subject:I know this can be done but I'm pulling my hair out trying to figure it out

Hello all,

What I'm trying to do is allow my users to be able to import / upload their own images into the interactive form but for the life of me cannot figure out / remember how to do this.

I've tried writing and using all sorts of JavaScript code and I'm at the end of my rope.

Would someone please be kind enough to lend me a hand and show me how this is done?

All help would be extremely grateful and my head would thank you too lol.

Cryo


Posted: 29 Apr 2011 03:14 AM
Left Button SpacerView user's profile profileRight Button Spacer
 
 
gkaiseril
gkaiseril

Total Messages 3000

Subject:I know this can be done but I'm pulling my hair out trying to figure it out

It can only be done if the form is crated using LiveCycle Designer (XML form). Forms created in Acrobat using the AcroForm tool bar can not provide this service.

George Kaiser


Posted: 29 Apr 2011 08:13 AM
Left Button SpacerView user's profile profileRight Button Spacer
 
 
Cryotech
Cryotech

Total Messages 2

Subject:I know this can be done but I'm pulling my hair out trying to figure it out

Hello,

Not sure what the acroform tool bar is, so I'm guessing I didn't use that.

Actually, I use two different types of PDF creators that allow for Push Button Icon change so that shouldn't be an issue.

I know it can be done because I've seen it done. In fact, I have code that works to a point then Acrobat rejects it when before it never has.

Does anyone know of any javascript code that works in regards to changing an icon based on user image upload?

Thanks for the time and help.


Posted: 02 May 2011 02:13 PM
Left Button SpacerView user's profile profileRight Button Spacer
 
 
gkaiseril
gkaiseril

Total Messages 3000

Subject:I know this can be done but I'm pulling my hair out trying to figure it out

LiveCycle Designer has the ability to perform this task.

If you wan to use Acrobat, then you need to create a PDF of the image and import that to a button:

var f = this.getField("myPicture");
f.buttonSetCaption(row.FirstName.value + " " + row.LastName.value);
if (f.buttonImportIcon(row.Picture.value) != 0)
f.buttonImportIcon("/F/employee/pdfs/NoPicture.pdf");

Or process an Icon Stream:

Import an icon into the document-level named icons tree and add a toolbutton to the application.

this.importIcon("myIcon", "/C/temp/myIcon.jpg", 0);
var oIcon = util.iconStreamFromIcon(this.getIcon("myIcon"));
app.addToolButton({
cName: "myButton",
oIcon: oIcon,
cExec: "console.println('My Button!');",
cTooltext: "My button!",
nPos: 0
});


George Kaiser


Posted: 03 May 2011 09:24 AM
Left Button SpacerView user's profile profileRight Button Spacer
 
 
   
Go to previous topicPrev TopicGo to next topicNext Topic

go




Top | News | Developer | Find PDF Tools | Sponsorship | Tips | Home



Debenu's Planet PDF - a comprehensive site exclusively focused on Adobe Acrobat/PDF users and uses. Debenu's Planet PDF - Resources for Adobe Acrobat and PDF users

Please post PDF-related questions to our Planet PDF Forum forums.planetpdf.com. To send comments about this site please visit our contact page.
Planet PDF, Planet PDF Forum, PDF SDK - Debenu Quick PDF Library and Debenu are all copyright
© 2011 Debenu Pty Ltd.. All Rights Reserved. Privacy policy.