View Single Post
 
Old 07-05-2012, 11:01 AM
gbaker gbaker is offline Windows 7 32bit Office 2010 32bit
Competent Performer
 
Join Date: May 2012
Posts: 111
gbaker is on a distinguished road
Default Method or data member not found

I have a problem with some code that I wrote. It gives me an error called Method of data member not found. Don't understand and can't fix it.
Can you help???
Code:
With Sheet2
 
        'get rid of any null strings stored in the cells for Print
        With .Range("Cp3:Df3980")
            .Value = .Value
        End With
 
            With .Sort
 
           'set up the sort fields for Print on (data tab)
            With .SortFields
                .Clear
                .Add Key:=Sheet2.Range("Cp3:Cp3980"), _
                            SortOn:=xlSortOnValues, _
                            Order:=xlAscending, _
                            DataOption:=xlSortNormal
                .Add Key:=Sheet2.Range("Cq3:Cq3980"), _
                            SortOn:=xlSortOnValues, _
                            Order:=xlAscending, _
                            DataOption:=xlSortNormal
            End With
     End With
            'set up the rest of the sort and apply for Print
            
            .SetRange Sheet2.Range("Cp3:Df3980")
            .Header = xlNo
            .MatchCase = False
            .Orientation = xlSortColumns
            .SortMethod = xlPinYin
            .Apply
    End With
Reply With Quote