private void cmdDownload_Click(object sender, EventArgs e) { //CFSDownloadRequest // Setup EMassaging Object EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadService EM = new EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadService(); // setup Authentication objects EMsgAPI_CFSDownload_201101.RequestAuthentication reqAuth = new EMsgAPI_CFSDownload_201101.RequestAuthentication(); EMsgAPI_CFSDownload_201101.XDDSAuthType XDDSAuth = new EMsgAPI_CFSDownload_201101.XDDSAuthType(); EMsgAPI_CFSDownload_201101.UIDType uid = new EMsgAPI_CFSDownload_201101.UIDType(); // init Authentication objects XDDSAuth.Password = txtAccessCode.Text; uid.Value = txtUserId.Text; XDDSAuth.RequesterID = uid; reqAuth.Item = XDDSAuth; // Setup Premiere Connect Request / Response and CFSDownload Request / Result EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.Request Request = new EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.Request(); EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.Response Response = new EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.Response(); EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadRequest Submit_Request = new EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadRequest(); EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadResult Submit_Result = new EMsgAPI_Demo.EMsgAPI_CFSDownload_201101.CFSDownloadResult(); // Setup Proxy server and EMsgAPIConnect URL for posting data Set_Server_and_Proxy(EM); // Setup Reqeust Object // Setup Reqeust Object Request.ReceiverKey = EM.Url; Request.Authentication = reqAuth; // Assign Reqeust and Response objects to EM Object EM.RequestValue = Request; EM.ResponseValue = Response; Submit_Request.RelativePath = "/testfile.html"; try { Submit_Result = EM.CFSDownload(Submit_Request); } catch (Exception ex) { System.Console.WriteLine(ex.Message); System.Console.Read(); return; } if (Submit_Result != null) { if (Submit_Result.Status.StatusCode != "0") { MessageBox.Show(Submit_Result.Status.StatusMessage, "Error"); } } string emfilename = "emresponse.xml"; string resfilename = "result.xml"; //string reqfilename = "request.xml"; try { //This will output the response, result and request(if uncommented) to XML files in the //installed directory. This can be very usefull for debugging or ir help is requested from //the EMAPI support team if (chkResult) { serializeResult(emfilename, EM.ResponseValue); serializeResult(resfilename, Submit_Result); //serializeResult(reqfilename, Submit_Request); } } catch (IOException io_error) { MessageBox.Show("Error - " + io_error, "Error", MessageBoxButtons.OK); } }