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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to set borders to Excel in macro

hi,

when download  to excel activesheet which is pivot chart,

how can i set borders to this chat?

followings are expression i wrote in qv module

sub download_excel

set obj = ActiveDocument.GetSheetObject("CH01")

 

  frame = obj.frame

  frame.BorderEffect = 1

  obj.SetBorder frame

obj.SendToExcel

end sub

when i excute this script then

displayed property is not supported by object.

does anyone know some solutions about this case?

Regards,

3 Replies
Not applicable
Author

sorry,

not supported property is  'obj.frame'

Not applicable
Author

HI,

Try this

Sub download_excel

Set obj = ActiveDocument.GetSheetObject("CHo1")

Set P = obj.GetProperties

P.Layout.Frame.BorderEffects=1

obj.SetProperties P

End Sub

Best of luck

Not applicable
Author

hi, Satish

thank you for your advice.

i tryed script you wrote,

but it occured same error...

'script -------------------------------------------------------------------

sub download_excel

 

  set obj = ActiveDocument.GetSheetObject("CH01")

 

                    Set P = obj.GetProperties

                    P.Layout.Frame.BorderEffects=1

                    obj.SetProperties P

 

          obj.SendToExcel

 

End Sub