Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help macro excel

Dear, I do not understand a problem and I can not solve. When you run a macro that creates an excel workbook I have the sgte. code:

ActiveDocument.Sheets ( "Stock"). Activate

appExcel.Worksheets.Add.name = "Stock"

ActiveDocument.GetSheetObject ( "CH06"). CopyTableToClipboard true
appExcel.ActiveSheet.Paste

In the execution sgte throws me the error: 'Error in Paste method of Worksheet Class'

The funny thing is that this occurs in the execution on the Server, to test the macro on my pc gives me the error. The object under dynamic gluing is a table of at most 16 rows and 10 columns ....

To eliminate the error comment leave that part of the macro, but now gives me error in another line:

appExcel.Columns ( "A: A"). Select

the message that tells me is: Unknown runtime error, 'appExcel.Columns (..). Select'


The other curious fact is that, while the model on the server, sometimes it works without problems.


Well, I hope someone can help me and sorry for writing but do not speak English .....

2 Replies
Not applicable
Author

Hi,

Try yo select a cell before the paste.

Not applicable
Author

First of all thanks for responding. Look, I make the selection as follows:


appExcel.Range("B7").Select

I have the impression that it must be something in the server configuration .... Since a PC running smoothly.