• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Error-1004, unable to set the Orientation of the PivotField class

Mithun Sarkar

New Member
Code:
>>> use code - tags <<<
Code:
'' Clearing Pivot
For Each TmpVar1 In pT_Br.PivotFields
'' TmpVar1.ClearAllFilters
TmpVar1.Orientation = xlHidden  <------ this is the problem line
Next TmpVar1
For Each TmpVar1 In pT_Br.DataFields
TmpVar1.Orientation = xlHidden
Next TmpVar1

Any comments, remarks, feedback, etc. would be greatly appreciated.

I didn't have this problem with previous version of operating system. Upgrade of Windows 10 with Latest Updates (NgW Windows 10 21H2 Upgrade) . I have faced the problem after installing Windows 10 with Latest Updates (NgW Windows 10 21H2 Upgrade). Is this a coincidence or did I miss a setting somewhere?

I have attached the screenshot and using all code.

Thanks and Regards,
Mithun
 

Attachments

Last edited by a moderator:
Code:
>>> use code - tags <<<
Code:
'' Clearing Pivot
For Each TmpVar1 In pT_Br.PivotFields
'' TmpVar1.ClearAllFilters
TmpVar1.Orientation = xlHidden  <------ this is the problem line
Next TmpVar1
For Each TmpVar1 In pT_Br.DataFields
TmpVar1.Orientation = xlHidden
Next TmpVar1

Any comments, remarks, feedback, etc. would be greatly appreciated.

I didn't have this problem with previous version of operating system. Upgrade of Windows 10 with Latest Updates (NgW Windows 10 21H2 Upgrade) . I have faced the problem after installing Windows 10 with Latest Updates (NgW Windows 10 21H2 Upgrade). Is this a coincidence or did I miss a setting somewhere?

I have attached the screenshot and using all code.

Thanks and Regards,
Mithun

I'm also having the same problem, I believe it could be something from the update.
 
Mithun Sarkar
You've shown few lines of code and ... a Word-file.
You should able to send an Excel sample file, which shows Your case much better to get replies.
 
Back
Top