MessageBox.Show("文件下载完成");
this.Cursor = Cursors.Default;
this.btnDownload.Enabled = true;
}
private void fileReceive(int rowID)//接受远程文件
{
string fn = this.tMaterial.Rows[rowID]["FilePath"].ToString();
fn = fn.Substring(fn.LastIndexOf('\\') , fn.Length - fn.LastIndexOf('\\'));
try
{
saveFs = new FileStream(this.folderBrowserDialog1.SelectedPath + fn, FileMode.Create);
}
catch (Exception ex)
{
this.querryObj.audioStreamClose();
MessageBox.Show("创建文件时失败:" + ex.Message);
return;
}
byte[] audioByte;
while (true)
{
try
{
audioByte = this.querryObj.audioStreamTran();
}
catch (System.Runtime.Remoting.RemotingException ex)
{
|