Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

QlikView calling external app. Need help from experts !

Hi,

I am given with a requirement which is a bit tuff for my knowledge in qlikview.

I really expects guidance and help from experts and long timers.

I'll explain my customer requirement here.

We have currently a qlikview (version 11) dashboard where the user can select one survey_id from a list box and then when he presses the 'show survey' button, this opens a image curresponding to the survey_id selected. This is pretty much easy as survey images has same name as that of the corresponding survey ids and giving the following command ='\\HNWPQLIK01\PGImages\' & SURVEY_ID & '.tif' in launch action of this button will serve the purpose. The problem with this set up is, that users cannot select multiple survey_ids and see the images together.

So in order to facilitiate this, we have downloaded a 3rd party Image2PDF converter which can be used using comman line methord. In DOS window, I am able to run a command that will run the .exe and creates the PDF at the desired location and opens this up.

My requirement is to find a methord where, the user when selects multiple survey ids and click on the 'show survey' button, will be able to see a PDF opened up with the images of the selected survey IDs.

At this point, I am totally confused how to proceed.

How to achive this? Is it like I have to create a DOS command (as a string) dynamicaly including the names of the survey images that need to be converted to PDF and be opened? If that is the case, how can I run this DOS command on a qlikview button click ?

Also, I dont have an idea how to pass the selected 'multiple surevy ids' to create the DOS command.

A sincere guidance would help me a lot as at this point I have no clue how to achieve this.

Thanks

sircute

7 Replies
Anonymous
Not applicable
Author

Hi Sircute,

You can use a button with a LAUNCH action to run an .exe file and pass parameters.

For pulling the selected or possible values from a field you can use either GetFieldSelections() or Concat() I guess.

nstefaniuk
Creator III
Creator III

Hello.

Firstly, the constraints:

- Only desktop client ? No Web?

- The tool that creates PDF can take multiple images as source? If yes how can he do that ? Just add a parameter with the list of images separated by a comma ?

If the tool that creates PDF has no syntax to manage multiple images, you can't use it for your need and you have to search for an other one.

If he has a syntax to do that, please give it to us, and so we could explain you how to achieve it (probably with concat as Johannes has said).

Not applicable
Author

hi nstefaniuk,

Thanks for the response.

- I am developing the dashboard in a qlikview desktop client. Once this works fine, I am expecting to deploy this in accesspoint..and also the Image2PDFConverter also in the server, so that this will work there fine. But am not sure, if this set up will prompt the user to see the PDF file when they click the button in accesspoint view. Because, the PDF will be created in server, and will it be opening in user's system?

- This tool has the capability to take muliple images and show in single PDF as multiple pages. I was just exporing in the example .bat files

For single image conversion and opening, the command is

C:\Image2PDFCommandLineTool\V2-73\Image2PDF.exe -UseActualImageDPI -image "C:\Image2PDFCommandLineTool\V2-73\Examples\Test images\IMAGE1.jpg" -output "C:\Test.pdf"-OpenPDF -OutlineTitle "Example images"

For multiple images it is shown as

C:\Image2PDFCommandLineTool\V2-73\Image2PDF.exe -UseActualImageDPI -image "C:\Image2PDFCommandLineTool\V2-73\Examples\Test images\*.jpg" -output "C:\Test.pdf"-OpenPDF -OutlineTitle "Example images"

Yes, the muliple images example just selects ALL images from a particular folder. I am yet to figure aout how to use this command to have just images of our choice (like may be comma seperated)

This image to PDF converter is a small size tool.

http://www.utilitywarrior.com/Image-to-PDF-Command-Line-Tool.htm is the site where I downloaded this tool and you can actually download it for free (link is available down on the left hand side)

nstefaniuk
Creator III
Creator III

Ok, so 2 things:

1) if the final usage is on access point don't develop using a commande line tool, you will have big issues to use it in access point. In this case it's REALLY better to search for a PHP / ASP / JAVA code that you put in a web page.

When users click on button you open the web page, with in the URL the values you need (concatenated with function Concat). In technical language, you will consume a webservice through a GET method, with parameters. The service will take the parameters, read the requested images, create the PDF, then answer to the request with the PDF (or a web page, in fact, no need of PDF).

2) As far I can judge, your tool doesn't allow to choose the multiple files, so you need at least 2 step:

- 1 step to clean a temp folder then copy inside the images requested by users

- 1 step to produce the PDF for these images

You can have big issues if there are concurrent calls on this "component", so refer to the point 1)

Good luck

nstefaniuk
Creator III
Creator III

In fact for point 1, it's really easy to ask in PHP or ASP forum the code to display the n images for the images given in parameters, with a separator.

You just need a PHP server to give access to users (take care or security of course). Maybe you can use the Qlikview server or a IIS on the Qlikview server (but in IIS it's not a PHP page).

Not applicable
Author

Hi nstefaniuk,

Thanks for the patience to explain.

Things are getting clearer for me. But I have no prior experience in PHP,ASP or webservices.

You have mentioned that

"1) if the final usage is on access point don't develop using a commande line tool, you will have big issues to use it in access point."

Does this mean that this particular tool cannont be used for the purpose. I am just copy pasting some portion of intro help  from this tools installation manual. which among the 2nd and 3rd versions would be apt for my requirement?

"In general, our utilities are available in three different versions depending on your requirements:

Desktop Application: This is a fully featured Windows application which has been designed to be both easy and intuitive to use. This version of a utility provides the quickest and most accessible way to produce a PDF using an interface that has been split up into related tabbed sections.

However, because it uses a graphical user interface, this type of utility is not suitable for repetitive tasks as it requires manual operation. For repetitive and batch oriented requirements either of the two other utility versions will be more appropriate, see below.

Command Line Tool: This is run from a DOS command line environment (or batch file) and is ideal for automated and repetitive batch use including CGI integration. Control over the entire functionality of the utility is achieved through the use of parameters passed to it from the command line when it is run. These commands can also be put in script/configuration files which are themselves passed as parameters to the utility.

Dynamic Link Library (DLL): This exposes the entire functionality of a utility through an Application Programming Interface (API) that can be included and used with most development environments (regardless of language used). API interfaces are provided for C, C++, Visual Basic 6 and for .net using Interop Services for C#, C++, J# and Visual Basic."

If this involve scripting/coding in Java or PHP..is there an easy way to learn them ?

Thanks,

sircute

nstefaniuk
Creator III
Creator III

They don't speak of web languages on their site, so I really think you should not use this tool.

You could use it like that:

- a PHP/APS script read the parameters

- temps folder is cleaned

- the needed files are copied in temp folder

- a command line is launched to generate the PDF

- the PDF is copied in a folder with a specific name

- the PHP/ASP answers the URL of the PDF

but it's very ugly for a lot of reasons.

Anyway, in Access Point, how to you want to share the generated PDF ? Shared folder or what ?