Delete Previous Twitter Posts/Tweets

Author:
Russell Solberg

Published Date:
9/29/2009

Comments


Tags
  • Tweet
  • Twitter
  • Twitterizer

 

TweetDelete Download

I created a very simple tool that you can download to delete your tweets & retweets. It has no warranty and will most likely not be improved until mid 2010. Click Here To Download TweetDelete

We've all done it, created a post or a tweet with a typo or simply published something that we would love to remove. When it comes to twitter, one of your few options for handling this is hovering over your tweet and clicking on the recycle bin. Just when you thought you were done, you then get to say "OK" I'm sure that is what I really wanted to do.

I've been looking for a tool that would allow me to delete all of my previous tweets at once, or at least more than one at a time, but never found one that seemed to work very well. So I decided, that I would leverage my understanding of the Twitterizer Framework to also destroy my previous tweets in a quick Console Application.

Step 1:

Make sure that you have the latest version of the Twitterizer Framework.

Step 2:

Create and/or open a new project insde of Visual Studio (my example is a Console Application)

Step 3:

Add a reference to the Twitterizer DLL that you downloaded in Step 1 to your project.

Step 4:

Program.cs

using Twitterizer.Framework; 
namespace DeleteMyTweets
{
   
class Program
   
{
       
private static string UserName = "MyUserName";
       
private static string Password = "MyPassword";
       
private static Twitter twitter = new Twitter(UserName, Password);
       
       
static void Main(string[] args)
       
{
           
while(true)
           
{
               
TwitterStatusCollection twitterStatusCollection = GetTweets();
               
if(twitterStatusCollection.Count <= 0)
               
{
                   
break;
               
}
               
for (int i = 0; i < twitterStatusCollection.Count; i++ )
               
{
                    twitter
.Status.Destroy(twitterStatusCollection[i].ID);
               
}
           
}
       
}
       
       
protected static TwitterStatusCollection GetTweets()
       
{
           
return twitter.Status.UserTimeline();
       
}
   
}
}