When it comes to creating reports that highlight the current status of your assets, it can be a challenge to retrieve and present the data in a meaningful way.
Fortunately, with Geocortex Reporting you can include feature attachments in your PDF reports, allowing you to share the current status of an asset with various stakeholders.
End users can select the features that they want to report on and then generate a report that can include both attribute information along with any attachments that may have been uploaded by field workers.
We explore precisely how this is done in this week’s Geocortex Tech Tip.
“Hi, my name is Darren and I’m a developer on the product team.
Today, we’re going to look at how you could include feature attachment images in a report. To include feature attachments in earlier versions of Geocortex Reporting, you have to be using an on-premises edition and configure a script.
Now, we’ve added two controls that simplify the display a feature attachment images. Furthermore, the controls can be used in both the on-premises and software-as-a-service editions of Geocortex Reporting.
Let’s take a look!
We’ll start by looking at the single feature attachment control. This control allows you to display individual feature attachment images in a report. Here, I have a very simple report that uses a feature layer as its data source.
I’ll go ahead and add a label to my report, I’ll just call that ‘Image 1’ for now. Then, I’ll go ahead and drag a single feature attachment control onto my design surface. With that control selected, I’ll come over here to the right and take a look at the properties. First, we’ll look at the image quality.
If the image that you want to include is very high resolution, this can result in your report size being very large, so if that’s a concern you can go ahead and decrease the quality of your image which will result in the size of your PDF being smaller.
The second property to be aware of is this image number property and to describe this, I’ll go ahead and go over to my feature service. Here, I’m looking at the attachment information for a specific feature in my feature service. You can see that I have four images attached to this feature and I’ve gone ahead and labelled them one, two, three, four and also added the number to the image itself just to help us visualize things when we run the report.
So, keeping in mind our images one, two, three, four. I’ll come back to my report and the order of those images corresponds to our image number here. If I want to show image number one, I’ll go ahead and leave that as a one and preview my report.
Here, we can see that the first image from our attachment info’s has been included in the report. If you want, you can add additional feature attachment images to your report.
I’ll go ahead and add another label to the design surface here, just going to call this one ‘Image 3’. I’m going to add another single feature attachment control to the design surface. This one, I
I’ll give a low-quality and set the image number to number three. We’ll preview this again, and I will see that we now have feature attachment number one and feature attachment number three in our report.
Next, we’ll take a look at the multiple feature attachment control. This control allows you to display one or more feature attachment images in a grid-like matter. Here’s my original simple report. I’ll go ahead and add a label, just call that ‘Images,’ and then I’ll go ahead and drag a multiple feature attachments control onto the design surface.
With the control selected, I’ll come over here and look at the properties. You’ll see image quality, which we discussed briefly earlier. Let’s go ahead and set this to medium. We also have this max attachment properties, which indicates the maximum number of attachments that will be displayed in the grid-like fashion and then the columns property, which indicates the number of images that will be displayed horizontally in our grid.
I’ll leave both of those at one, and we’ll just preview the report quickly here. We’ll see that our very first image is inserted into the report here.
To demonstrate the max attachments property, I’ll increase this to three and this control has the ability to grow in a vertical direction, so as you increase the number of attachments, the control will expand and push controls below it downwards. To demonstrate that, I’ll just throw another text box into here, leave that labelled as such and preview the report.
Here, we should see that we have three images stacked vertically and our label has been pushed down to the bottom.
Finally, I’ll demonstrate the ‘Columns’ property. I’ll just increase that to two, run the report and we’ll see that it doesn’t look great. What’s happening is – while the control can grow vertically, it can’t grow horizontally. What’s happening is we’re fitting two images side-by-side in this space. To improve that appearance a little bit, what we can do is increase the width of our control, just to give those images a little bit more room. Let’s try that again. There we go!
There’s one final property that you may want to be aware of, that’s in the layout section here. You have the ability to configure horizontal and vertical spacing between images. I’m just going to go ahead and increase the horizontal spacing, decrease the vertical spacing and run this one final time.
Here we’ll see that our images are slightly farther apart and squeezed in a little bit tighter vertically.
That’s it for today. Thank you for watching!”
Want to see more of Geocortex Reporting in action? Watch the latest webinar, book a demo, or learn more about the product by clicking the button below.