Jump to content

Excel (or PDF) document preview in activex container... is possible?


osvaldo

Recommended Posts

Hi to you guy!

I'm writing an application that collects data from a test machine and than creates a printed report based on an excel file template (xltx).

I'm able to create the final excel file to print (i'm using the Office Report Toolkit to do that) or save.

I let the user to select the template file on the fly, using the standard File Dialog Window and then run the VI that make the report...

Now the problem I'm not able to solve... He had request to have a little preview of the file selected that help him to

select the right template...

He would have a dialog with a listbox populated with the files names, and a box on the right that show the preview of the file

actualy selected in the listbox...:(

I've tried a number of methods to achieve the goal with no results!:frusty:

I've tried the PrintPreview ActivieX into an ActiveX container with no result!

Using the Excel ActiveX in ActiveX container lat me show the file, but I can't find a zoom property!!

Perhaps using the .NET container? I don't know how...

HELP ME!!!:wacko:

Anyone of you gurus knows a way to make that possible? :worshippy:

Best regards

Osvaldo

Link to comment

Osvald, I am sure there is a more elegant way than what I am about to suggest but it has worked for me for viewing PDF files.

Just create a web browser activex container and load the file to preview there. Let the browser decide that the correct application is to view the file (acrobat, other pdf viewer, excel, etc).

Michael

Link to comment

Osvald, I am sure there is a more elegant way than what I am about to suggest but it has worked for me for viewing PDF files.

Just create a web browser activex container and load the file to preview there. Let the browser decide that the correct application is to view the file (acrobat, other pdf viewer, excel, etc).

Michael

What idea!:thumbup1:

Unfortunately, the method works only with files that Internet Explorer is able to show independently or as a plug-in...:throwpc:

does not work with Excel spreadsheets, which instead are downlod and opened directly with Excel ...:angry:

Among the activeX is also available ThumbCtl ... I tried it and I saw the preview that makes the files as shown in the File Explorer ... but excel is not made the preview ... only the icon!:frusty:

Thanks for your help ... 'm open to any suggestions!:wacko:

Hello

Osvaldo

Link to comment

What idea!:thumbup1:

Unfortunately, the method works only with files that Internet Explorer is able to show independently or as a plug-in...:throwpc:

does not work with Excel spreadsheets, which instead are downlod and opened directly with Excel ...:angry:

Among the activeX is also available ThumbCtl ... I tried it and I saw the preview that makes the files as shown in the File Explorer ... but excel is not made the preview ... only the icon!:frusty:

Thanks for your help ... 'm open to any suggestions!:wacko:

Hello

Osvaldo

Could you convert it to a pdf before showing?

Alternatively you can use an activex control called DSO Framer that will allow you to open an office document to display. I don't know if you can open it directly in preview mode though.

I hope this helps

Michael

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.