csvout.writerow([name, followers])
print name + ", " + str(followers)
csvfile.close()[/CODE]
Edited by mikedemon, 11 July 2011 - 03:19 PM.
Edited by mikedemon, 11 July 2011 - 03:19 PM.
|
|
|
for name in listofnames: account = api.GetUser(name) followers = account.followers_count csvout.writerow([name, followers]) print name + ", " + str(followers)Unfortunately you didn't originally post your code in [noparse]
[/noparse] tags, so there's no way to tell what the indentation is like, but to me it seems like this problem would occur because of an indentation issue. So before I go further into this, here's the correct indentation: [code]for name in listofnames: account = api.GetUser(name) followers = account.followers_count csvout.writerow([name, followers]) print name + ", " + str(followers)Please tell me if you're still having an issue.
0 members, 1 guests, 0 anonymous users