Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Export To Excel

HI all

I have a straigth table and iam using the MAcro to export it to excel which i found in the community ,After runing this i get the straight table exported to excel as it is .

I also have the list box (LT02) by name Region in the dashboard.and there is one more list box (LT10) by Branches

the macro iam using and the code for it is :

sub ExportToExcel_Divisionwise

Dim CLApp, XLDoc,XLSheet

  set XLApp = CreateObject("Excel.Application") ' Define Object

  XLApp.Visible = True 'Visible set as true

  set XLDoc = XLApp.Workbooks.Add 'Open new workbook

  set XLSheet = XLDoc.Worksheets.Add

  ActiveDocument.GetSheetObject("CH09").CopyTableToClipboard TRUE

  XLSheet.paste

this will give me the data like this attachment

But i want the second row of the generated excel to show me the Regions from the Region List Box and third row should show me the Branches from Branche List Box .

Thanks in Advance

4 Replies
fkeuroglian
Partner - Master
Partner - Master

Hi,

i see the macro works ok, export the table CH09 as you have in qlikview? you want to export some list box too?

what are the region and branch in your qlikview document?

is there export the object as you see in qlikvew? you want to add some object in the excel export?

Not applicable
Author

HI fernando Thanks for the reply

Iam attching my qlikview file , U can see there i have Region And Branches ,

When export to Excel the first row should have the all Headers and second row in the excel should be region and the third row should be Branches .

I hope iam clear ,

Thanks in advance

fkeuroglian
Partner - Master
Partner - Master

Hi, no attached qvw in your respond

attach again ,thank you

Fernando

Not applicable
Author

Thanks Fernando For ur reply ,

  PLease find the attachement of the QVW