dl = Left(dp, 3)
ChDrive dl
ChDir dpDim dp As String
dp = ActiveWorkbook.Path
Workbooks.Open (dp & "\Vorlage.xls")ds = Cells(2, 1)
ds = Cells(1, 2)
desweiteren:FileCopy "Vorlage.xls", neudateigeht bei mir auch nicht ohne Pfadangabe, keine Ahnung wieso das bei Dir läuft.Sub DateiSchreiben()
Dim dp As String
Dim ds As String
dp = ActiveWorkbook.Path & "\"
Workbooks.Open (dp & "Vorlage.xls")
'ds = Cells(2, 1) falsch, ist Zelle A2 in neu anlegen.xls
ds = Workbooks("Vorlage.xls").Sheets("Tabelle1").Cells(1, 2)
Workbooks("Vorlage.xls").Close
neudatei = Cells(1, 1) & ".xls"
FileCopy dp & "Vorlage.xls", dp & neudatei
Cells(1, 1) = Left(neudatei, Len(neudatei) - 4)
Cells(2, 1) = ds
Application.DisplayAlerts = False
ActiveWorkbook.Save
ActiveWorkbook.Close
Application.DisplayAlerts = True
End Sub
Automatische Miniaturansicht
mxuxix 15.02.2007 - 270 Hits - 1 Antwort
automatische benutzeranmeldung aktivieren
broah 19.05.2007 - 346 Hits - 1 Antwort
automatische windows updates
Viper01 02.02.2008 - 125 Hits - 2 Antworten