Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
In my qvw file i written OnOpen action to reload my file with macro code. Now it's reloading the file. And I also written on OnPostReload to create qvd file for table box.
- But it is not working for me. i.e it is not generating qvd file for me.
Can anyone help me
Hi,
Can you please attach any sample file.
Regards
Hi Rahul,
I'm attaching sample qvw file for your reference.
Hey Hi,
You can use this way.
Regards
Hi Mr. Nokia,
Try to export the file to other driver than C:\
I got the "Cannot open file C:\Test.qvd for writing!" message. After I've set target to D:\ (obj.Export "D:\Test.qvd",",") it worked.
Regards!
Hi,
The code you have written is working at my side.
Can you please tell us what is the error that you are getting.
Regards,
Kaushik Solanki
ActiveDocument.Export creates a SKV file, which is a semicolon separated textfile.
According to QlikView API Guide the QVD can be generated by using ExportEx with Export Format set to 4 as example below shows.
set obj = ActiveDocument.GetSheetObject("CH01")
obj.ExportEx "C:\test.qvd", 4
I think you are reloading manually. Don't do that create a macro code to reload and apply OnOpen trigger. Now just close the qvw file and open now it should create qvd file. But it is not creating qvd file.
- I tried like this i had created a batch file to reload this qvw file. Then it is creating qvd file when batch file is running.
Ah, did not realize that you have a Table box in the example. You need to select the export function carefully, depending on how you plan to execute it. And then of course there need to be write access to the folder where file is written.
Export Straight table chart to QVD;
set obj = ActiveDocument.GetSheetObject("CH01")
obj.ExportEx "C:\test.qvd", 4
Export Table Box object on ServerSide to QVD;
set obj = ActiveDocument.GetSheetObject("TB01")
obj.ServerSideExportEx "C:\test.qvd", 4