Here is the code I am using. I found it on a similar thread in this forum. The code runs without error but does not update the variable to 1 when a file exists. Any suggestions?
Expand|Select|Wrap|Line Numbers
- Dim AllFiles() As String = System.IO.Directory.GetFiles("\\fcfpsvr1\share\medicare\bipimport\incomingfiles\", "*.txt")
- Dim I As Integer
- For I = 0 To AllFiles.Length - 1
- If AllFiles(I).StartsWith("PDE") Then
- System.Diagnostics.Debug.WriteLine(AllFiles(I))
- Dts.Variables("SourceFileExists").Value = 1
- End If
- Next