ExcelHome技术论坛

 找回密码
 免费注册

QQ登录

只需一步,快速开始

快捷登录

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

[求助] [求助]行高的单位"磅"到底为多少?谢谢!急!

[复制链接]

TA的精华主题

TA的得分主题

发表于 2003-5-19 18:58 | 显示全部楼层 |阅读模式
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件       ★免费下载 ★       ★ 使用帮助
1磅=?厘米

TA的精华主题

TA的得分主题

发表于 2003-5-30 17:54 | 显示全部楼层
那么列宽也是么!!? 好像不大对劲啊

TA的精华主题

TA的得分主题

发表于 2003-5-31 21:21 | 显示全部楼层
是啊,行高、列宽怎么确定(尺寸),对我来说太难了,我只有通过打印才能具体知道(主要是对准纸上已有表格)

TA的精华主题

TA的得分主题

发表于 2003-5-31 22:23 | 显示全部楼层
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件       ★免费下载 ★       ★ 使用帮助
试着比较。

TA的精华主题

TA的得分主题

发表于 2003-6-19 15:41 | 显示全部楼层
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件       ★免费下载 ★       ★ 使用帮助
这几个宏怎么执行阿,没看懂

TA的精华主题

TA的得分主题

发表于 2003-6-19 17:46 | 显示全部楼层
不好意识,我知道怎么用了,谢谢。 但还是有个问题,,行高和列宽都设置为1厘米,但结果是一列“列宽”只有0.98厘米,一行“行高”却有1.02厘米,为什么呢?

TA的精华主题

TA的得分主题

发表于 2007-2-18 21:15 | 显示全部楼层
[广告] Excel易用宝 - 提升Excel的操作效率 · Excel / WPS表格插件       ★免费下载 ★       ★ 使用帮助

八楼的正是我想问的。为什么每次精确设备行高、列宽时系统都会自动改变设定值啊

TA的精华主题

TA的得分主题

发表于 2007-2-19 01:49 | 显示全部楼层

请查看:jwb444“分享mm为单位的行高列宽(标尺)”的贴子

72磅=1吋=25.4mm

行高和列宽都有一个步进值(1像素),当屏幕显示分辨率为DPI=96时,行高的步值为0.75磅。

http://club.excelhome.net/viewthread.php?tid=221838&replyID=&skin=0

[此贴子已经被作者于2007-2-19 1:59:46编辑过]

TA的精华主题

TA的得分主题

发表于 2008-4-9 09:35 | 显示全部楼层

TA的精华主题

TA的得分主题

发表于 2008-8-21 11:56 | 显示全部楼层
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用  · 内置多项VBA编程加强工具       ★ 免费下载 ★      ★使用手册
QUOTE:
以下是引用xiaog在2003-6-1 0:15:00的发言:
按厘米或英寸改变单元格的行高、列宽(微软)

'一、按厘米改变
Sub RowHeightInCentimeters()
       Dim cm As Integer
       ' Get the row height in centimeters.
       cm = Application.InputBox("Enter Row Height in Centimeters", _
           "Row Height (cm)", Type:=1)
       ' If cancel button not pressed and a value entered.
       If cm Then
           ' Convert and set the row height
           Selection.RowHeight = Application.CentimetersToPoints(cm)
       End If
   End Sub

   Sub ColumnWidthInCentimeters()

       Dim cm As Integer, points As Integer, savewidth As Integer
       Dim lowerwidth As Integer, upwidth As Integer, curwidth As Integer
       Dim Count As Integer

       ' Turn screen updating off.
       Application.ScreenUpdating = False
       ' Ask for the width in inches wanted.
       cm = Application.InputBox("Enter Column Width in Centimeters", _
           "Column Width (cm)", Type:=1)
       ' If cancel button for the input box was pressed, exit procedure.
       If cm = False Then Exit Sub
       ' Convert the inches entered to points.
       points = Application.CentimetersToPoints(cm)
       ' Save the current column width setting.
       savewidth = ActiveCell.ColumnWidth
       ' Set the column width to the maximum allowed.
       ActiveCell.ColumnWidth = 255
       ' If the points desired is greater than the points for 255
       ' characters...
       If points > ActiveCell.Width Then
           ' Display a message box because the size specified is too
           ' large and give the maximum allowed value.
           MsgBox "Width of " & cm & " is too large." & Chr(10) & _
               "The maximum value is " & _
               Format(ActiveCell.Width / 28.3464566929134, _
               "0.00"), vbOKOnly + vbExclamation, "Width Error"
           ' Reset the column width back to the original.
           ActiveCell.ColumnWidth = savewidth
           ' Exit the Sub.
           Exit Sub
       End If
       ' Set the lowerwidth and upper width variables.
       lowerwidth = 0
       upwidth = 255
       ' Set the column width to the middle of the allowed character
       ' range.
       ActiveCell.ColumnWidth = 127.5
       curwidth = ActiveCell.ColumnWidth
       ' Set the count to 0 so if it can't find an exact match it won't
       ' go on indefinitely.
       Count = 0
       ' Loop as long as the cell width in is different from width
       ' wanted and the count (iterations) of the loop is less than 20.
       While (ActiveCell.Width <> points) And (Count < 20)
           ' If active cell width is less than desired cell width.
           If ActiveCell.Width < points Then
               ' Reset lower width to current width.
               lowerwidth = curwidth
               ' set current column width to the midpoint of curwidth
               ' and upwidth.
               Selection.ColumnWidth = (curwidth + upwidth) / 2
           ' If active cell width is greater than desired cell width.
           Else
               ' Set upwidth to the curwidth.
               upwidth = curwidth
               ' Set column width to the mid point of curwidth and lower
               ' width.
               Selection.ColumnWidth = (curwidth + lowerwidth) / 2
           End If
           ' Set curwidth to the width of the column now.
           curwidth = ActiveCell.ColumnWidth
           ' Increment the count counter.
           Count = Count + 1
       Wend
   End Sub


‘******************************************************************
'二、按英寸改变
Sub RowHeightInInches()
       Dim inches As Integer
       ' Get the desired column width.
       inches = Application.InputBox("Enter Row Height in Inches", _
           "Row Height (Inches)", Type:=1)
       ' If the cancel button was not pressed.
       If inches Then
           ' Convert and set the column height.
           Selection.RowHeight = Application.InchesToPoints(inches)
       End If
   End Sub

   Sub ColumnWidthInInches()

       Dim inches As Integer, points As Integer, savewidth As Integer
       Dim lowerwidth As Integer, upwidth As Integer, curwidth As Integer
       Dim Count As Integer

       ' Turn screen updating off.
       Application.ScreenUpdating = False
       ' Ask for the desired width in inches.
       inches = Application.InputBox("Enter Column Width in Inches", _
           "Column Width (Inches)", Type:=1)
       ' If the cancel button for the input box is pressed, exit the
       ' procedure.
       If inches = False Then Exit Sub
       ' Convert the entered inches to points.
       points = Application.InchesToPoints(inches)
       ' Save the current column width setting.
       savewidth = ActiveCell.ColumnWidth
       ' Set the column width to the maximum allowed.
       ActiveCell.ColumnWidth = 255
       ' If points wanted is greater than points for 255 characters.
       If points > ActiveCell.Width Then
           ' Display a message box (the specified size is too large), and
           ' let user know maximum allowed value.
           MsgBox "Width of " & inches & " is too large." & Chr(10) & _
               "The maximum value is " & Format(ActiveCell.Width / 72, _
               "0.00"), vbOKOnly + vbExclamation, "Width Error"
           ' Reset the column width back to the original.
           ActiveCell.ColumnWidth = savewidth
           ' Exit out of the Sub from here.
           Exit Sub
       End If

       ' Set the lowerwidth and upperwidth variables.
       lowerwidth = 0
       upwidth = 255
       ' Set the column width to the middle of the allowed character range.
       ActiveCell.ColumnWidth = 127.5
       curwidth = ActiveCell.ColumnWidth

       ' Set the count to 0 so if it can't find an exact match it won't go
       ' indefinitely.
       Count = 0
       ' Loop as long as the cell width is different from width desired
       ' and the count (iterations) of the loop is less than 20.
       While (ActiveCell.Width <> points) And (Count < 20)
           ' If active cell width is less than desired cell width.
           If ActiveCell.Width < points Then
               ' Reset lower width to current width.
               lowerwidth = curwidth
               ' Set current column width to the midpoint of curwidth and
               ' upwidth.
               Selection.ColumnWidth = (curwidth + upwidth) / 2
               ' If active cell width is greater than desired width.
           Else
              ' Set upwidth to the curwidth.
              upwidth = curwidth
              ' Set column width to the mid point of curwidth and lower
              ' width.
              Selection.ColumnWidth = (curwidth + lowerwidth) / 2
           End If
           ' Set curwidth to the width of the column now.
           curwidth = ActiveCell.ColumnWidth
           ' Increment the count counter.
           Count = Count + 1
       Wend
   End Sub

谢谢,很不错的

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

本版积分规则

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

GMT+8, 2024-10-23 20:29 , Processed in 0.050577 second(s), 10 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 1999-2023 Wooffice Inc.

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

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

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