Ivan, I had to make a small change to the macro you forwarded to me, as the winzip files are renamed with a suffix of spl instead of zip. It works great, but here is my delema, I need to specify which file to open, so I have made a cell on the worksheet (named ppfile1) that is where I will type in the file name I need to open (it is actually the date YYYYMMDD.spl) I can not seem to get it to work using the normal naming conventions I normally use in my programming,
any ideas on how to correct this??
Function WinZipIt(Source As String, Target As String, spl As Boolean)
Dim ZipIt As String
Dim UnZipIt As String
ZipIt = "C:Program filesWinzip" & "winzip32 -a "
UnZipIt = "C:Program FilesWinzip" & "winzip32 -e "
If spl Then
Shell (ZipIt & Target & Source)
Else
Shell (UnZipIt & Target & Source)
End If
End Function
Sub priorperiod()
filepp = Range("ppfile1").Value
WinZipIt " C:UnzippedFilesHere", filepp, False
''This is where I get a syntax error (filepp)''
End Sub
_________________
Russell
This message was edited by ermccarthy on 2002-03-03 13:46