0

I am trying to convert vsd/vsdx to png file, it was working fine until today. here is my code. please help. code stuck on convertApi.ConvertAsync line, it doesn't throw any error. but it just doesn't return anything.

public async void PrintVisioToTIFF(string VisioFilePath, string Filepath, string Extension)
    {
        var convertApi = new ConvertApi("XXXXXXXXXXXXXXX");

        if (Extension == ".vsd")
        {
            var convert = await convertApi.ConvertAsync("vsd", "jpg",
                new ConvertApiFileParam("File", VisioFilePath));
            await convert.SaveFilesAsync(Filepath);
        }
        else if (Extension == ".vsdx")
        {
            var convert = await convertApi.ConvertAsync("vsdx", "png",
                new ConvertApiFileParam("File", VisioFilePath));
            await convert.SaveFilesAsync(Filepath);
        }
    }
Peter Huber
  • 3,052
  • 2
  • 30
  • 42
  • If it worked before but now no longer, you have to describe what you have changed in the meantime. Also the meaning of "code stuck on convertApi.ConvertAsync line, it doesnt throw any error. but it just doesn't return anything" is not clear. Do you mean it is stuck and never returns from the call to convertApi.ConvertAsync() or do you mean that it does return but the return value is null ? – Peter Huber Mar 24 '21 at 03:36
  • yes it never return from call. We doesn't change anything it was working fine but stop suddenly. Also convertApi.ConvertAsync function saves .vsd file to png on a specific folder. Then we are showing that converted image on website. – Anuj Rawat Mar 24 '21 at 15:17
  • Please try to convert your vsd/vsdx files using the web interface https://www.convertapi.com/vsd-to-tiff and check if it is not related to the files. – Jonas Mar 25 '21 at 05:39

0 Answers0