Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
HI All,
I am quite familiar with exporting a chart to xls with the code below, but when I try to use this with a text object, it does not seem to work. My text object is ...
= 'text ' & today(2)
..but if I try and use the code below changing CH01 to TX01, it all goes wrong on the xls coming up with a previous copy / paste or cell reference or ?.
Has anyone any ideas please ?
set obj = ActiveDocument.getsheetobject("CH01")
obj.CopyTableToClipboard true
xlSheet.Range ("A1").Select
xlsSheet.Paste
Thanks in advance
Bob
 rubenmarin
		
			rubenmarin
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Maybe you used that 'true' parameter, CopyTextToClipboard and CopyBitmapToClipboard doesn't have parameters, it should be only:
set obj = ActiveDocument.getsheetobject("TX01")
obj.CopyTableToClipboard
xlSheet.Range ("A1").Select
xlsSheet.Paste
I didn't tested, there is an API guide usually in C:\ProgramData\QlikTech\QlikView Documentation\Automation wich explains macro functions
 rubenmarin
		
			rubenmarin
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi Nick,
Not sure CopyTableToClipboard works with Text objects, instead you can try CopyTextToClipboard to copy the text or CopyBitmapToClipboard to copy the the object as an image (with all his pros and cons)
 
					
				
		
HI,
Unfortuantely that throws up a macro error of 'wring number of arguments or...'
😞
 rubenmarin
		
			rubenmarin
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Maybe you used that 'true' parameter, CopyTextToClipboard and CopyBitmapToClipboard doesn't have parameters, it should be only:
set obj = ActiveDocument.getsheetobject("TX01")
obj.CopyTableToClipboard
xlSheet.Range ("A1").Select
xlsSheet.Paste
I didn't tested, there is an API guide usually in C:\ProgramData\QlikTech\QlikView Documentation\Automation wich explains macro functions
 
					
				
		
Thank you 🙂 removing the 'true' did it 😉
