Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# .NET
Hello,
I am working on windows application which record Skype call .till now code working fine ..but now i want to start call recording when user receive a call or connect to call(right now i am using a button to star recording) i just want to skip this button
here is my code
 

string conversationFile = String.Format(Utils.SkypeConversationsFile, Utils.SkypeConversationsFolder, Utils.CurrentCallNumber);
             FileNameTextBox.Text = conversationFile;
             try
             {
                 if (!Directory.Exists(Utils.SkypeConversationsFolder))
                     Directory.CreateDirectory(Utils.SkypeConversationsFolder);
             }
             catch (Exception ex)
             {
                 MessageBox.Show("Cannot create directory " + Utils.SkypeConversationsFolder + ". " + ex.Message);
             }
            // Start recording
            if (Utils.CurrentCallNumber>0)
            {
                string recordOutputCommand = String.Format(Utils.RecordOutputCommand, Utils.CurrentCallNumber, conversationFile);
                string recordInputCommand = String.Format(Utils.RecordInputCommand, Utils.CurrentCallNumber, conversationFile);
                NativeCalls.SendSkypeMessage(recordOutputCommand);
                NativeCalls.SendSkypeMessage(recordInputCommand);
                RecordButton.Content = "Stop Recording";
            }
            else if(Utils.CurrentCallNumber==0)
            {
                // Stop recording
                string recordEndOutputCommand = String.Format(Utils.RecordEndOutputCommand, Utils.CurrentCallNumber);
                string recordEndInputCommand = String.Format(Utils.RecordEndInputCommand, Utils.CurrentCallNumber);
                NativeCalls.SendSkypeMessage(recordEndOutputCommand);
                NativeCalls.SendSkypeMessage(recordEndInputCommand);
                RecordButton.Content = "Start Recording";
                MakeConversationFile();
            }
        }
Posted 21-Apr-13 1:00am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



Advertise | Privacy | Mobile
Web01 | 2.8.1411022.1 | Last Updated 21 Apr 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100