Deleting a poll

  Previous topic Next topic JavaScript is required for the print function Mail us feedback on this topic! Mail us feedback on this topic!  

The following sample code shows how you can delete a poll including its answers.

 

[C#]

 

using CMS.Polls;

 

...

 

        string pollName = "testingSitePoll";

 

        // Get poll info for the specified code name

        PollInfo pollObj = PollInfoProvider.GetPollInfo(pollName);

 

        // Delete the poll

        PollInfoProvider.DeletePollInfo(pollObj);

 

Page url: http://devnet.kentico.com/docs/5_5r2/devguide/index.html?api_deleting_a_poll.htm