Cmostaert Posted December 4, 2012 Share Posted December 4, 2012 Hi there, We are very new to fusionpro. We are creating a template that will have 1 variable text box and one variable graphic box. We deifinitley have the text box under control. Our problem is the graphics box. All we need is to have an agent picture in there. We have that box looking a the folder with the images in there but nothing is showing up in the box. We were told by one person that our .jpg wasn't saved corectly. We don't know what that means. Our photo person said there's only one way to save a .jpg. I'm looking for something we've missed. Thanks Cmostaert Quote Link to comment Share on other sites More sharing options...
step Posted December 4, 2012 Share Posted December 4, 2012 Does your data specify the file name of the jpg you wish to pull in? Or are your jpgs named in accordance to a field in your data such as "Agent Name"? If so, you want to create a graphic rule that tells FP what image to pull in for each record: return CreateResource("/PATH TO IMAGES/" + Field("Agent Name") + ".jpg"); Then draw a graphic frame and apply the rule you just created to it by selecting the "[Field or Rule]" drop down on the "properties" palette. Quote Link to comment Share on other sites More sharing options...
Cmostaert Posted December 4, 2012 Author Share Posted December 4, 2012 Our data has a field for Agent photo and in that field are the names of the photos that is for each person in the data. In training we just told it what field to look in and the photo showed up in the box. Is there more to it than that? It seemed so easy in training... Cmostaert Quote Link to comment Share on other sites More sharing options...
step Posted December 4, 2012 Share Posted December 4, 2012 Did the steps I detailed not give you the results you expected? Have you tried to compose the job and taken a look at the .msg log to see why it's failing to pull in the graphic as you anticipated? Quote Link to comment Share on other sites More sharing options...
Cmostaert Posted December 4, 2012 Author Share Posted December 4, 2012 I can do that??? I will definitely check that out. Quote Link to comment Share on other sites More sharing options...
esmith Posted December 4, 2012 Share Posted December 4, 2012 In training we just told it what field to look in and the photo showed up in the box. Is there more to it than that? It seemed so easy in training... To do what you are trying to do, you have to predefine your field data types. By default they are all imported via the wizard as text. You need to go to "Data Definition > Edit Flat File Data" under the FusionPro menu and change the "Agent Photo" field to Graphic (this can also be done during data import via the Wizard). Quote Link to comment Share on other sites More sharing options...
Cmostaert Posted December 4, 2012 Author Share Posted December 4, 2012 We do have that as a graphic. That was my first thought when we started this form, but we have it right. Let me ask you this. Within the template, can we change the sample data it is looking at? Thank you so much. This is helping me understand some things. Cmostaert Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted December 4, 2012 Share Posted December 4, 2012 Within the template, can we change the sample data it is looking at? FusionPro -> Data Definition -> Change Input File Quote Link to comment Share on other sites More sharing options...
Cmostaert Posted March 20, 2013 Author Share Posted March 20, 2013 Hi there, We are still having this issue with the photos of the agent not showing up on the template. We thought we had a rule that would work but it won't. Here is the rule we were given to use - see if anyone can tell me what we doing wrong. agentPhoto = CreateResource(Field("AgentPhoto"), "graphic" , true); If (agentPhoto.exists) return agentPhoto; else return Resource("photo_not_found.pdf"); I'm not sure what the phot not found .pdf is. When we used this rule we keep getting an error message something about the resource in the last line. Please help. Chris Quote Link to comment Share on other sites More sharing options...
Dan Korn Posted March 20, 2013 Share Posted March 20, 2013 Hi there, We are still having this issue with the photos of the agent not showing up on the template. We thought we had a rule that would work but it won't. Here is the rule we were given to use - see if anyone can tell me what we doing wrong. agentPhoto = CreateResource(Field("AgentPhoto"), "graphic" , true); If (agentPhoto.exists) return agentPhoto; else return Resource("photo_not_found.pdf"); I'm not sure what the phot not found .pdf is. When we used this rule we keep getting an error message something about the resource in the last line. Please help. Chris I think that whoever gave you that rule assumed that you would have a generic placeholder graphic to show when the agent photo isn't found, but they didn't know exactly what the name of the generic graphic would be. So they wrote it to call out a named resource instead of a particular file name. There are basically three things you can do: 1. Add a Graphic resource to the job with that name. From the menu in Acrobat, select, FusionPro -> Data Definition -> Input Options, click "Edit Resources", then "Add", browse to the file you want, and set the Resource name (NOT the file name) to "photo_not_found.pdf". OR 2. Change that last line to call CreateResource instead of Resource, like so: else return CreateResource("photo_not_found.pdf");Then can either rename your generic file to "photo_not_found.pdf", or change that last line of the rule to whatever the name of the file is. OR 3. If you don't want any graphic to show up at all when there's no agent photo, change the last line of the rule to this:else return NullResource();Pick any one of those. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.