Microsoft Office Excel ® Kod Kılavuzu

Microsoft Office Excel® Code Guide

20 Ekim 2005 Perşembe

Region Naming And Deletion

'Module1
Option Explicit
Dim Alan As Range, Sayfa As Worksheet

Sub AlanTanımıVeSilinmesi() '[Region naming and deletion]
On Error GoTo Hata
Set Sayfa = ThisWorkbook.Sheets("Sayfa1")
Set Alan = Sayfa.Range("A2:F6")
Sayfa.Names.Add Name:="Bölge1", RefersToR1C1:=Alan
Application.Goto Reference:="Bölge1"
Sayfa.Range("Bölge1").Value = 1
[A1].Value = Application.WorksheetFunction.Sum(Range("Bölge1"))
Sheets("Sayfa1").Names("Bölge1").Delete
Exit Sub
Hata:
End Sub

10 Ekim 2005 Pazartesi

The Cell Free / Full, And Signing Status



'Module1

Option Explicit
Dim i As Single
Dim X

Sub HücreBoşDoluVeSayısalOlmaDurumu() '[The Cell Free / Full, And Signing Status]
On Error GoTo Hata
For i = 2 To 18
X = Cells(i, 1).Value
If VBA.IsArray(X) = False Then Cells(i, 3) = "False"
If VBA.IsDate(X) = False Then Cells(i, 4) = "False"
If VBA.IsEmpty(X) = False Then Cells(i, 5) = "False"
If VBA.IsError(X) = False Then Cells(i, 6) = "False"
If VBA.IsMissing(X) = False Then Cells(i, 7) = "False"
If VBA.IsNull(X) = False Then Cells(i, 8) = "False"
If VBA.IsNumeric(X) = False Then Cells(i, 9) = "False"
If VBA.IsObject(X) = False Then Cells(i, 10) = "False"
If VBA.IsArray(X) = True Then Cells(i, 3) = "True"
If VBA.IsDate(X) = True Then Cells(i, 4) = "True"
If VBA.IsEmpty(X) = True Then Cells(i, 5) = "True"
If VBA.IsError(X) = True Then Cells(i, 6) = "True"
If VBA.IsMissing(X) = True Then Cells(i, 7) = "True"
If VBA.IsNull(X) = True Then Cells(i, 8) = "True"
If VBA.IsNumeric(X) = True Then Cells(i, 9) = "True"
If VBA.IsObject(X) = True Then Cells(i, 10) = "True"
Next i
Hata:
End Sub

1 Ekim 2005 Cumartesi

Field Marking



'Module1

Option Explicit
Dim Hücre As Range
Dim Aranan As String, Bulunan As String

Sub Alanİşaretleme() '[Field Marking]
On Error GoTo Hata
Aranan = Range("E2").Value
If Aranan = "" Then
GoTo Hata
Else
Set Hücre = Range("A1:A65536").Find(Aranan, , , , , xlNext)
Bulunan = Hücre.Address
Set Hücre = Range("A1:A65536").Find(Aranan, , , , , xlPrevious)
Bulunan = Bulunan & ":" & Hücre.Address
Range(Bulunan).Select
End If
Exit Sub
Hata:
Range("A1").Select
End Sub

Blog Arşivi

Bu gadget'ta bir hata oluştu

Bu Blogda Ara

Contributor

Contributor
Mustafa ULUSARAÇ İstanbul, TÜRKİYE
free counters
T. C. Central Bank Indicative Exchange Rates
Currency Exchange Rate Widget,Currency Converter Widget
Borsa İstanbul