Selecting a cell next to the current cell in excel

خرید بک لینک

I'm doing a small vba in excel which change the value of blank cells to "NO DATA". This is what I've done so far:

Private Sub Worksheet_Change(ByVal Target As Range)
On Error GoTo hell:
Application.Goto reference:="DBtable"
Selection.SpecialCells(xlCellTypeBlanks).Select
Selection.SpecialCells(xlCellTypeBlanks).Value = "NO DATA"

'I DON'T KNOW WHAT TO PUT HERE

hell:
End Sub

What I would like to happen is that, whenever I add a new record on my table and it contains a blank cell, it should be changed immediately with the "NO DATA" value and then the selection should be on the next cell of the last cell I modified. What's happening right now is that after it change the blank cell to the value I want, it selects the whole table. Please help me!

Recent Questions...

ما را در سایت Recent Questions دنبال می‌کنید

برچسب: selecting a cell in vba,selecting a cell in excel,selecting a cell phone,selecting a cell in excel vba,selecting a cell phone carrier,selecting a cell without deselecting another,selecting a cell in the current column,selecting a cell from another worksheet,selecting a cell range in excel,selecting a cell using vba, نویسنده: استخدام کار بازدید: 628 تاريخ: سه شنبه 19 مرداد 1395 ساعت: 12:44

صفحه بندی