Excel精英培训网

 找回密码
 注册
数据透视表40+个常用小技巧,让你一次学会!
查看: 2713|回复: 3

[已解决]列表框多列显示时,可用百分数分配列宽吗?

[复制链接]
发表于 2012-3-31 15:16 | 显示全部楼层 |阅读模式
比如,有一需要显示四列的列表框,我想第一列显示占40%,第二列显示占20%,第三列显示占25%,第四列显示占15%,该怎么写?

最佳答案
2012-3-31 15:21
.width*0.4,.width*0.25......
excel精英培训的微信平台,每天都会发送excel学习教程和资料。扫一扫明天就可以收到新教程
发表于 2012-3-31 15:21 | 显示全部楼层    本楼为最佳答案   
.width*0.4,.width*0.25......
回复

使用道具 举报

 楼主| 发表于 2012-3-31 15:37 | 显示全部楼层
With ListBox1
.ColumnWidths = .Width * 0.5 & "," & .Width * 0.15 & "," & .Width * 0.15 & "," & .Width * 0.2
End With
回复

使用道具 举报

 楼主| 发表于 2012-3-31 15:37 | 显示全部楼层
With ListBox1
.ColumnWidths = .Width * 0.5 & "," & .Width * 0.15 & "," & .Width * 0.15 & "," & .Width * 0.2
End With
回复

使用道具 举报

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

本版积分规则

小黑屋|手机版|Archiver|Excel精英培训 ( 豫ICP备11015029号 )

GMT+8, 2024-5-15 06:40 , Processed in 0.392228 second(s), 8 queries , Gzip On, Yac On.

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

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