Ejemplo n.º 1
0
 public void SendFilesToAsync(IPEndPoint ipEndPoint, string[] files, SendFilesProgress progress, object state,
                              SendFilesComplete complete)
 {
     new Thread(new ThreadStart(() =>
     {
         try
         {
             SendFilesTo(ipEndPoint.Address, files, state, progress);
             if (complete != null)
             {
                 complete(state, null);
             }
         }
         catch (Exception e)
         {
             if (complete != null)
             {
                 complete(state, e);
             }
         }
     })).Start();
 }
Ejemplo n.º 2
0
 public void SendFilesToAsync(IPEndPoint ipEndPoint, string[] files, SendFilesProgress progress, object state,
     SendFilesComplete complete)
 {
     new Thread(new ThreadStart(() =>
         {
             try
             {
                 SendFilesTo(ipEndPoint.Address, files, state, progress);
                 if (complete != null)
                 {
                     complete(state, null);
                 }
             }
             catch (Exception e)
             {
                 if (complete != null)
                 {
                     complete(state, e);
                 }
             }
         })).Start();
 }