Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have 3 QVWs (L1, L2 and L4) for an app, First I have to open and reload L1 (it brings data from multiple sources into Qlikview and creates QVD) after that I have to run L2 (it transforms the data and does some calculation and creates QVD), At last I have to run L4 which brings in the data from QVD created by L2 and creates dashboard with that.
I was thinking is there any way, I can run L1, L2 and L4 from L4 itself so that I don't need to open and load each QVW individually. Any suggestion would be greatly appreciated.
Thanks,
hi there
create a macro in qlikview with the following code and place it in a button
sub load()
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L2.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L3.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L4.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\Lx.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
end sub
Make 4
Load 3
Right?
I have already added 3 buttons in L4 . First reloads L1
second reloads L2 and third L4. However I need all the actions in one button, When
I add all the actions to load L1, L2 and L4 in one button, all the QVWs start
loading simultaneously, But I want them to load one after one.
Create a Batch file and then create an object in QV to run the bat.
To create the batch file open notepad and write
cd C:\Program Files\QlikView
qv.exe /r C:\...path to document 1 goes here
qv.exe /r C:\...path to document 2 goes here
etc....
Save as filename.bat
Then create a button in your main sheet to execute the bat file you created.
If you didn't do a default installation of QlikView the cd C:\Program Files\QlikView will not be the correct path
hi there
create a macro in qlikview with the following code and place it in a button
sub load()
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L2.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L3.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\L4.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
Set App = ActiveDocument.GetApplication
Set newdoc = App.opendoc ("C:\Lx.qvw")
newdoc.Activate
newdoc.reload
newdoc.save
newdoc.closedoc
end sub
Bingo, this is something I was looking for...cheers to you ...