Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

VB Macro won't run on a new (migrated) QlikView server.

We are having a problem that I am hoping to get a little more brainpower on.

Our current environment has the IIS webserver running on a Windows 2008 virtual machine and the QlikView server running on a physical Windows 2008. QlikView is version 10.0.8935.7 and unfortunately an upgrade isn't in the cards for right now.

The application works fine in the current web environment. It also runs fine in the QlikView Desktop. Part of the logon process and a large part of the application relies heavily on the Visual Basic Macro code - the macro is about 2800 lines long. We know this isn't ideal, but again, a large rewrite effort isn't an option at the moment.

The situation is that we have to migrate our servers to the main datacenter, and as a result, we are moving the QlikView server from one physical server to another. The old Windows server is Windows 2008 Enterprise Server build 6002 SP2 with 8 processors with 64 Gig of RAM while the new server is Windows 2008 Enterprise Server R2 build 7601 SP1 64 bit with 24 processors and 128 Gig of RAM.

I have installed the same version of QlikView on the new server, duplicated directories and files, compared all settings in the old and new QMC and QEMC pages, and have done a binary compare on files in the QlikView directories and the Program Data\QlikTech directories with very minor differences, mainly the InterOp.Qlikview.dll. I have copied it from the old server to the new server, but it didn't change the behavior.

The problem seems to be that anything that uses more than a few lines of macro code (login, move from one tab to another, etc.) refuses to function. I have included examples of the Macro code - a button on the first sheet displayed calls the XXX_AccessSystem sub which runs fine until it calls the ResetProcess sub - at that point it appears to hang. I have verified this by placing a setting a variable at various points in the macro - by using an input box set to that variable I can see the progress. Any variable put in the Reset_Process sub will never get set/displayed.

Can anyone think of something I may have missed?

Thanks.

2 Replies
vikasmahajan

Please check with setting is done in document.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
Not applicable
Author

Hello Lyndon Nelson,

I would suggest you to debug the macro. If you are using v11, the debug option is no more available. But you can put message boxes after every line in the macro and test, where it fails.

Then once you spot the line which does not work, try finding an alternative or a way to replace just that line.

For example:

In version 10, this works:

sFileName = replace(replace(Now(), "/", "_"), ":", "_") &"_"& getVariable("vOSUser")
set oChart = ActiveDocument.GetSheetObject("CH01")
b = oChart.ServerSideExport (getVariable("Path")&FileName&".txt", ";" , 0, true)

In version 11, above does not work, but instead this works:

sFileName = Replace(Replace(Now(), "/", "_"), ":", "_") &"_"& ActiveDocument.Variables("vOSUser").GetContent.String

set oChart = ActiveDocument.GetSheetObject("CH01")
oChart.ServerSideExportEx ActiveDocument.Variables("Path").GetContent.String&FileName&".txt", ";" , 1

Let me know how it goes.

Thanks,

Robinson