Sub
klick()
Dim
wkb
As
Workbook
Dim
kennzeichen
As
String
Dim
fin
As
String
Dim
zeile
As
Long
Dim
spalte
As
Long
Dim
datum
As
Date
Dim
textboxDat
As
Date
Dim
name
As
String
Dim
auslieferungsDat
As
String
Dim
uhrzeitAuslieferung
As
Variant
Set
wkb = Workbooks.Open(
"C:\Dokumente und Einstellungen\P325130\Desktop\kopie Neuwagen\Neuwagenmanagement.xls"
)
wkb.Activate
Sheets(
"Neuwagen"
).Activate
zeile = ActiveSheet.Cells(Rows.Count, 1).
End
(xlUp).Row + 1
zeile = zeile + 1
textboxDat = TextBox3.Value
datum = Cells(zeile, 13)
If
(textboxDat = datum)
Then
Set
rangeobj = Cells.Find(What:=textboxDat, After:=ActiveCell, LookIn:=xlValues, LookAt _
:=xlWhole, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:= _
False
, SearchFormat:=
False
)
If
rangeobj
Is
Nothing
Then
MsgBox
"Das Datum "
+ datum +
" wurde nicht gefunden!"
Else
zeile = rangeobj.Row
spalte = rangeobj.Column
If
(Cells(zeile, 14).Value =
"9:00"
)
Then
Label120.Caption = Cells(zeile, 5).Value
End
If
End
If
End
If
End
Sub