Sort Problem: Unreadable Content

Virtual Blue

New Member
Joined
Dec 7, 2009
Messages
3
I am getting this message come up often when I open my workbook:"Excel found unreadable content in 'mybook.xlsm'. Do you want to recover the contents of this workbook? If you trust the source of this workbook, click Yes."I click Yes and get another dialog box with the following information:"Excel was able to open the file by repairing or removing the unreadable content.Removed Records: Sorting from /xl/worksheets/sheet3.xml part"It tends to vary between 3 different sheets although once the message came up relating to 2 sheets.Can anyone tell me why this would be coming up and what I should be looking for to prevent it from happening?ThanksVB
 
PM
dear RoryA

i added it but unfortunately the problem isn't solved.

every time i use that code, next time i open the file the error appear.

any other clue?

thanks any way.
 
Upvote 0

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
PM
dear RoryA

i added it but unfortunately the problem isn't solved.

every time i use that code, next time i open the file the error appear.

any other clue?

thanks any way.


Hi ymk080690,

I have been facing similar issue for a while and finally got it working using the solutions provided here. I added both '.sortfields.clear' and worksheet name for the range in Key parameter and it worked. When I added only one of them it didn't work.

Hope this helps.

Thanks
 
Upvote 0
Hi ymk080690,

I have been facing similar issue for a while and finally got it working using the solutions provided here. I added both '.sortfields.clear' and worksheet name for the range in Key parameter and it worked. When I added only one of them it didn't work.

Hope this helps.

Thanks

i am copying you my code
please have a look if i did every thing as instructed or not:
Code:
ActiveWorkbook.Worksheets("member").AutoFilter.Sort.SortFields.Add Key:= _
        ActiveWorkbook.Worksheets("member").Range("A2"), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:= _
        xlSortNormal
        With ActiveWorkbook.Worksheets("member").AutoFilter.Sort
        .Header = xlYes
        .MatchCase = False
        .Orientation = xlTopToBottom
        .SortMethod = xlPinYin
        .Apply
    End With
    ActiveWorkbook.Worksheets("member").Sort.SortFields.Clear
Re:
 ActiveWorkbook.Worksheets("DataBase").AutoFilter.Sort.SortFields.Add Key:= _
        ActiveWorkbook.Worksheets("DataBase").Range("A2"), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:= _
        xlSortNormal
        With ActiveWorkbook.Worksheets("DataBase").AutoFilter.Sort
        .Header = xlYes
        .MatchCase = False
        .Orientation = xlTopToBottom
        .SortMethod = xlPinYin
        .Apply
    End With
    ActiveWorkbook.Worksheets("DataBase").Sort.SortFields.Clear
MainS.Activate
    ActiveWorkbook.Worksheets("main page").AutoFilter.Sort.SortFields.Add Key:= _
        ActiveWorkbook.Worksheets("main page").Range("A4"), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:= _
        xlSortNormal
        With ActiveWorkbook.Worksheets("main page").AutoFilter.Sort
        .Header = xlYes
        .MatchCase = False
        .Orientation = xlTopToBottom
        .SortMethod = xlPinYin
        .Apply
    End With
    ActiveWorkbook.Worksheets("main page").Sort.SortFields.Clear
thanks
 
Last edited by a moderator:
Upvote 0

Forum statistics

Threads
1,226,227
Messages
6,189,753
Members
453,567
Latest member
kentbarbie

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top