ExcelHome技术论坛

 找回密码
 免费注册

QQ登录

只需一步,快速开始

快捷登录

搜索
EH技术汇-专业的职场技能充电站 妙哉!函数段子手趣味讲函数 Excel服务器-会Excel,做管理系统 效率神器,一键搞定繁琐工作
HR薪酬管理数字化实战 Excel 2021函数公式学习大典 Excel数据透视表实战秘技 打造核心竞争力的职场宝典
让更多数据处理,一键完成 数据工作者的案头书 免费直播课集锦 ExcelHome出品 - VBA代码宝免费下载
用ChatGPT与VBA一键搞定Excel WPS表格从入门到精通 Excel VBA经典代码实践指南
查看: 612|回复: 1

Word中如何根据句子的长短排序?

[复制链接]

TA的精华主题

TA的得分主题

发表于 2020-6-9 08:46 | 显示全部楼层 |阅读模式
Word中如何句子的长短排序?.zip (12.79 KB, 下载次数: 7)
Word中如何根据句子的长短排序?
Excel中有个len函数,可以方便地根据长短排序,Word中怎么按照句子长短排序呢?
It was the right decision because it saved moneyand protected the earth.
I was a little nervous to tell him that I had failed the exam the third time.
After learningof his dog’s death, he stopped cooking at once.
The boy passedthe newspaper through the door and ran away.
At first, her husband argued that thefamily should stay together at theirhome.
When she came home, I already had all myclothes packed up in my bag.
Nobody knowswhen the terrible weather is going to end.
Find someone you trust and go and tell themwhat is happening to you.
Take a good look at yourself in the mirror and answer these questions.
This kind of small ants can live almost anywhere.
The weather makes a big difference in ourdaily lives.
Here’s a look at why the weather is an important part of our daily lives.
The rain brings new life and washes away the old things.
Natural plants would die and we’d be left with a desert of a world.
Did you know that the wind can blow away pollution and illness?

TA的精华主题

TA的得分主题

发表于 2020-6-11 05:34 | 显示全部楼层
  1. Sub aaaa段落排序()
  2.     Dim i As Paragraph
  3.     For Each i In ActiveDocument.Paragraphs
  4.         i.Range.InsertBefore Text:=i.Range.Characters.Count & vbTab
  5.     Next
  6. '
  7.     Selection.WholeStory
  8.     Selection.ConvertToTable Separator:=wdSeparateByTabs, NumColumns:=2, _
  9.         NumRows:=15, AutoFitBehavior:=wdAutoFitFixed
  10.     With Selection.Tables(1)
  11.         If .Style <> "网格型" Then
  12.             .Style = "网格型"
  13.         End If
  14.         .ApplyStyleHeadingRows = True
  15.         .ApplyStyleLastRow = False
  16.         .ApplyStyleFirstColumn = True
  17.         .ApplyStyleLastColumn = False
  18.         .ApplyStyleRowBands = True
  19.         .ApplyStyleColumnBands = False
  20.     End With
  21.     Selection.Sort ExcludeHeader:=False, FieldNumber:="列 1", SortFieldType:= _
  22.         wdSortFieldNumeric, SortOrder:=wdSortOrderAscending, FieldNumber2:="", _
  23.         SortFieldType2:=wdSortFieldSyllable, SortOrder2:=wdSortOrderAscending, _
  24.         FieldNumber3:="", SortFieldType3:=wdSortFieldSyllable, SortOrder3:= _
  25.         wdSortOrderAscending, Separator:=wdSortSeparateByCommas, SortColumn:= _
  26.         False, CaseSensitive:=False, LanguageID:=wdSimplifiedChinese, _
  27.         SubFieldNumber:="段落数", SubFieldNumber2:="段落数", SubFieldNumber3:="段落数"
  28.     ActiveWindow.ActivePane.VerticalPercentScrolled = 0
  29.     Selection.HomeKey Unit:=wdStory
  30. '
  31.     With ActiveDocument.Tables(1)
  32.         .Columns(1).Width = CentimetersToPoints(1)
  33.         .Columns(2).Width = CentimetersToPoints(14)
  34.     End With
  35. End Sub
复制代码

评分

1

查看全部评分

您需要登录后才可以回帖 登录 | 免费注册

本版积分规则

手机版|关于我们|联系我们|ExcelHome

GMT+8, 2024-11-24 08:47 , Processed in 0.034791 second(s), 15 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 1999-2023 Wooffice Inc.

沪公网安备 31011702000001号 沪ICP备11019229号-2

本论坛言论纯属发表者个人意见,任何违反国家相关法律的言论,本站将协助国家相关部门追究发言者责任!     本站特聘法律顾问:李志群律师

快速回复 返回顶部 返回列表