Powerpoint: How to use CreateVideo function to run synchronously

kamalasubha muthukumar 41 Reputation points
2021-02-03T13:22:37.573+00:00

Hi all,
I have implemented the C# code which generates video from ppt. I could see that CreateVideo() runs in an asynchronous manner. When the parent process closes the presentation, the function terminates the creation abruptly. Is there any way to call CreateVideo() function synchronous with the parent process?

Please find the code in the txt file.63454-program.txt

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,279 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Daniel Zhang-MSFT 9,636 Reputation points
    2021-02-04T08:06:38.497+00:00

    Hi kamalasubhamuthukumar-9493,
    You can achieve synchronization by checking Presentation.CreateVideoStatus property.
    Here is my test code you can refer to.
    Test result:
    63961-130.gif
    Best Regards,
    Daniel Zhang


    If the response is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.