Attribute VB_Name = "Kindle" Sub my_Clippings() ' ' my_Clippings Macro ' Selection.HomeKey Unit:=wdStory 'remove all tabs With Selection.Find .Text = "^t" .Replacement.Text = " " .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab before the "breaker" text that separates the records With Selection.Find .Text = "^p===" .Replacement.Text = "^t===" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab after the "breaker" text that separates the records, identifying the title of the next one With Selection.Find .Text = "===^p" .Replacement.Text = "===^t" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab before the type of content (notes, bookmark, highlight) With Selection.Find .Text = "^p-" .Replacement.Text = "^t-" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab before the "Loc." text that shows the location in the specific Kindle Document With Selection.Find .Text = "Loc." .Replacement.Text = " ^tLoc." .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab before the date added to the txt file With Selection.Find .Text = "| Added " .Replacement.Text = " ^t Added " .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab after the date added to the txt file With Selection.Find .ClearFormatting .Replacement.ClearFormatting .Text = "AM^p" .Replacement.Text = "AM^t" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Put a tab after the date added to the txt file With Selection.Find .ClearFormatting .Replacement.ClearFormatting .Text = "PM^p" .Replacement.Text = "PM^t" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' replaces general carriage returns with spaces, hopefully identifying those fields that are still content. With Selection.Find .Text = "^p" .Replacement.Text = " " .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll Selection.WholeStory WordBasic.TextToTable ConvertFrom:=1, NumColumns:=6, NumRows:=475, _ InitialColWidth:=wdAutoPosition, Format:=0, Apply:=1184, AutoFit:=0, _ SetDefault:=0, Word8:=0, Style:="Table Grid" ' Application.WindowState = wdWindowStateMinimize Selection.Find.ClearFormatting Application.WindowState = wdWindowStateNormal Selection.Find.ClearFormatting Selection.Find.Replacement.ClearFormatting Selection.Tables(1).Select Selection.Sort ExcludeHeader:=False, FieldNumber:="Column 1", _ SortFieldType:=wdSortFieldAlphanumeric, SortOrder:=wdSortOrderAscending, _ FieldNumber2:="Column 3", SortFieldType2:=wdSortFieldAlphanumeric, _ SortOrder2:=wdSortOrderAscending, FieldNumber3:="", SortFieldType3:= _ wdSortFieldAlphanumeric, SortOrder3:=wdSortOrderAscending, Separator:= _ wdSortSeparateByCommas, SortColumn:=False, CaseSensitive:=False, _ LanguageID:=wdEnglishUS, SubFieldNumber:="Paragraphs", SubFieldNumber2:= _ "Paragraphs", SubFieldNumber3:="Paragraphs" Selection.MoveRight Unit:=wdCell Selection.MoveRight Unit:=wdCell Selection.MoveRight Unit:=wdCell Selection.MoveRight Unit:=wdCell Selection.MoveRight Unit:=wdCell Selection.MoveRight Unit:=wdCell Selection.SelectColumn Selection.Columns.Delete Selection.Tables(1).Rows.SetLeftIndent LeftIndent:=-30.6, RulerStyle:= _ wdAdjustNone Selection.Tables(1).Columns(3).SetWidth ColumnWidth:=74.4, RulerStyle:= _ wdAdjustNone Selection.Tables(1).Columns(4).SetWidth ColumnWidth:=76.5, RulerStyle:= _ wdAdjustNone Selection.Tables(1).Columns(5).SetWidth ColumnWidth:=211.5, RulerStyle:= _ wdAdjustNone Selection.WholeStory Selection.Font.Size = 10 Selection.HomeKey Unit:=wdStory End Sub