Пакет содержит задачу сценария, показанную ниже ошибки
Dts Script task has encountered an exception in user code:
Exception has been thrown by the target of an invocation
Код задачи сценария
public void Main()
{
string Str_Filepath = Dts.Variables["User::FilePath"].Value.ToString();
bool bl_exist=false;
if (System.IO.File.Exists(Str_Filepath))
{
bl_exist = true;
}
else
{ bl_exist = false; }
Dts.Variables["User::V_Exist"].Value = bl_exist;
Dts.TaskResult = (int)ScriptResults.Success;
}