Quantcast
Channel: Tweetinvi a friendly Twitter C# library
Viewing all articles
Browse latest Browse all 4126

New Post: How I can add a friend to my friends list?

$
0
0
Hi.

I wont to add a friend:
        TwitterCredentials.SetCredentials("AccesToken", "AccesTokenSecret", "ConsumerKey", "ConsumerKeySecret");
        var usuario = User.GetUserFromScreenName(TxtUsuario.Text);
        var YoUsuario = User.GetLoggedUser();
        YoUsuario.Friends.add(usuario);
In the last line I've a exception because YoUsuario.Friends is a Null object

What's the correct method? Any can help me?

Thanks.

Viewing all articles
Browse latest Browse all 4126

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>