Kommentar einfügen.
09.09.2003 17:33:15
Alex
folgender Code :
Private Sub Worksheet_SelectionChange(ByVal target As Excel.Range)
Dim neuerwert
Dim kommentar As String
If ((Not Intersect(target, Range("H:H")) Is Nothing) And (Range("b13") = "Editor Mode")) _
And (Not IsEmpty(target)) Then
neuerwert = target.Value
target.Value = InputBox("eingabe:")
If target.Value = "" Then
target.Value = neuerwert
GoTo ende1
ElseIf target.Value = neuerwert Then
GoTo ende1
End If
kommentar = InputBox("Bitte Grund eingeben: ", "Kommentar")
MsgBox (kommentar)
MsgBox (VarType(Application.UserName))
--> target.Select
--> Selection.AddComment = kommentar
End If
ende1:
End Sub
Bei den Pfeilen würde ich dem ausgewählten Target gern einen Kommentar geben.
Leider klappt das wohl Aufgrund irgendwelcher Wrapper Angelegenheiten nicht.
wer kann mir helfen?
Vielen Dank im Vorraus.
Gruss Alex.