static void TestGetMaximumFileSize(string fileEx)
        {
            ClientResult <int> intTemp;

            intTemp = TranslationJob.GetMaximumFileSize(cc, fileEx);
            cc.ExecuteQuery();
            Console.WriteLine("GetMaximumFileSize for " + fileEx + " " + intTemp.Value);
        }
    /// <summary>
    /// print maximum file size of each supported file extension that the service will take
    /// </summary>
    static void GetMaximumFileSize()
    {
        SPServiceContext sc = SPServiceContext.GetContext(new SPSite(site));

        string[] fileEx = { "docx", "doc", "docm", "dotx", "dotm", "dot", "rtf", "html", "htm", "aspx", "ascx", "xhtml", "xhtm", "txt", "xlf", "xxx" };
        foreach (string ex in fileEx)
        {
            Console.Write(ex + ": ");
            Console.WriteLine(TranslationJob.GetMaximumFileSize(sc, ex).ToString());
        }
    }
 private void CreateThreadForFileSize(object fileExt)
 {
     try
     {
         ClientResult <int> intTemp;
         intTemp = TranslationJob.GetMaximumFileSize(cc, (string)fileExt);
         cc.ExecuteQuery();
         string result           = intTemp.Value.ToString();
         DispatcherOperation dop = Dispatcher.BeginInvoke(new Action <string>(PrintResult), result);
     }
     catch (Exception e)
     {
         DispatcherOperation dop = Dispatcher.BeginInvoke(new Action <string>(PrintResult), e.ToString());
     }
 }