Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
After updating the server with a Publisher license and moving all Excel generating tasks from Windows Task Scheduler to Supporting Tasks in QMC the export is failing due to the fact that the clipboard is not functioning.
For example, if I copy text 'abc' in notepad, later, when the Excel files are generated, they will contain only the 'abc' string. It`s like the QMC does not have permissions to clear and populate the clipboard.
Any ideas?
Hello,
if you use publisher you can't use "ActiveDocument" and so on in QV-macro, since it is a batch job. If you want to use your functionality through Publisher, you have to use "supporting Tasks" -> External Programs. There you can call every program, even the "normal" qv.exe.
Try something like this as commandline:
"C:\Program Files\QlikView\Qv.exe" /r "<PathToDashboard>\<DashboardName>.qvw"
If you are using QV12.20 SR7 and smaller, you have to add "/nodata" as parameter, due to a bug.
Kind regards
Peter
Sorry, I didn't read that you are already using supporting tasks.
Which version of QV do you use?
Could you post your Macro-code?
The cause might be the (service) user with which the publisher runs. I don't know if there are ways within the publisher to specify the user of such task - if not you could try to apply a RUNAS within the comandline or through an intermediate batch-file. Another possibility might be just to start the windows-task like:
schtasks.exe /Run /TN "QlikView Tasks\ExportAndPrint";
- Marcus
Hello,
Marcus, this is a good point. I didn't consider the problem could be the user.
I don't know a possibilty in publisher to specify a user. So we are testing everything with the service user.
- Maybe the service user isn't allowed to run Excel?
- Maybe the service user has no rights to write the Excel-File?
- Did you test your macro with the service user?
Peter
I thought about user permissions but I don`t think that is the case.
Excel runs ok, as I said in the first post, the problem is with the copy / paste command from qlikview to excel.
At first I would re-start the whole machine to exclude that any weird things cause this issue. If this doesn't help you could follow one of the various hints in this and within the linked postings, like clearing the clipboard before using it:
- Marcus
Already did that, also cleared the clipboard ahead by
Set WshShell = CreateObject("WScript.Shell")
WshShell.Run "cmd.exe /c echo. >NUL | clip", 0, True
I repeat, everything runs perfect outside Publisher. This has been a real headscratcher for me.