|
-
Sep 24th, 2000, 10:20 PM
#1
This is an exerpt of my code, it goes on like this 9 times! Ugh! I know I can shorten it by useing an array or an index but I havn't a clue how to make that work. Anyone feel like helping me?
Public Function MultiDirExport(ExportPath)
Dim DirExport As String
If frmMultiDir.txtDir(0).Text = "" Then
Exit Function
Else
DirExport = frmMultiDir.txtDir(0).Text
DosShell "dir /b " & DirExport & " >> C:\Windows\Temp\MP3_Export.txt"
End If
If frmMultiDir.txtDir(1).Text = "" Then
Exit Function
Else
DirExport = frmMultiDir.txtDir(1).Text
DosShell "dir /b " & DirExport & " >> C:\Windows\Temp\MP3_Export.txt"
End If
If frmMultiDir.txtDir(2).Text = "" Then
Exit Function
Else
DirExport = frmMultiDir.txtDir(2).Text
DosShell "dir /b " & DirExport & " >> C:\Windows\Temp\MP3_Export.txt"
End If
End Function
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|