예제 #1
0
 public bool ConvertToDoc(string source, string target)
 {
     try
     {
         AsposeConverter ac = new AsposeConverter();
         return ac.ConvertToDoc(source, target);
     }
     catch (Exception e)
     {
         // TODO: Add logging
         return false;
     }
 }
예제 #2
0
 public int ConvertToDocPwd(string source, string target, string password)
 {
     try
     {
         AsposeConverter ac = new AsposeConverter();
         ac.ConvertToDocPwd(source, target, password);
         return (int)ConverterMessages.OK;
     }
     catch (Exception e)
     {
         if (e is IncorrectPasswordException)
         {
             return (int)ConverterMessages.IncorrectPassword;
         }
         else
         {
             return (int)ConverterMessages.Error;
         }
     }
 }
예제 #3
0
 public int ConvertToRtfEx(string source, string target)
 {
     try
     {
         AsposeConverter ac = new AsposeConverter();
         ac.ConvertToRtf(source, target);
         return (int)ConverterMessages.OK;
     }
     catch (System.Exception e)
     {
         if (e is IncorrectPasswordException)
         {
             return (int)ConverterMessages.IncorrectPassword;
         }
         else
         {
             return (int)ConverterMessages.Error;
         }
     }
 }