您的位置:首页 > 其它

excel插入图片自动适应表格大小

2017-07-27 13:28 573 查看


ALT + F11

2

菜单 插入-----模块

3

键入

Sub PictureFitUnit()

    Dim sh As Shape

    For Each sh In ActiveSheet.Shapes

        sh.LockAspectRatio = False

        sh.Left = sh.TopLeftCell.Left

        sh.Top = sh.TopLeftCell.Top

        sh.Width = sh.TopLeftCell.Width

        sh.Height = sh.TopLeftCell.Height

    Next sh

End Sub

4

光标在模块中,F5执行
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: