国产一级a片免费看高清,亚洲熟女中文字幕在线视频,黄三级高清在线播放,免费黄色视频在线看

打開APP
userphoto
未登錄

開通VIP,暢享免費電子書等14項超值服

開通VIP
Excel 設置成回車后自動歸零

Excel    設置成回車后自動歸零

360U2005471648級分類:編程開發(fā)被瀏覽53次2019.11.08

推薦答案

匿名網(wǎng)友2019.11.09

Private Sub Worksheet_SelectionChange(ByVal Target As Range)

    Dim r1%, r%, c1%, c%

    r1 = Target.Row

    c1 = Target.Column

    If Application.MoveAfterReturnDirection = xlDown Then

        r = r1 - 1: c = c1

        If r1 = Cells.Rows.Count Then r = r1

    End If

    If Application.MoveAfterReturnDirection = xlUp Then

        r = r1 + 1: c = c1

        If r1 = 1 Then r = 1

    End If

    If Application.MoveAfterReturnDirection = xlToLeft Then

        r = r1: c = c1 + 1

        If c1 = 1 Then c = 1

    End If

    If Application.MoveAfterReturnDirection = xlToRight Then

        r = r1: c = c1 - 1

        If c1 = Cells.Columns.Count Then c = c1

    End If

    If r > 0 And c > 0 Then

        If Cells(r, c) <> "" Then

            Cells(r, c) = 0

            Cells(r, c).NumberFormatLocal = "G/通用格式"

        End If

    End If

End Sub

說明:此代碼不僅僅回車后自動歸零。

本站僅提供存儲服務,所有內容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權內容,請點擊舉報
打開APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
Excel VBA中關于 if or 的使用
文件夾下的所有工作簿內和所有工作表目錄
合并一個EXCEL多個sheet的內容到一個匯總sheet
Excel Excel VBA 數(shù)組排序
Excel讓選定單元格所在行和列顏色突出高亮顯示
考試座位編排vba
更多類似文章 >>
生活服務
分享 收藏 導長圖 關注 下載文章
綁定賬號成功
后續(xù)可登錄賬號暢享VIP特權!
如果VIP功能使用有故障,
可點擊這里聯(lián)系客服!

聯(lián)系客服