我需要帮助,我收到错误:输入字符串的格式不正确。提前谢谢。
错误选择的行是第一行
var getus = await _instaApi.GetUserAsync(listBox1.Items[s].ToString());
var userid = getus.Value.Pk;
var FollowResult = await _instaApi.FollowUserAsync(long.Parse(userid));
if (checkBox3.Checked == true)
{
var userFeed = await _instaApi.GetUserMediaAsync(listBox1.Items[s].ToString(), 1);
if (userFeed.Succeeded)
{
foreach (var media in userFeed.Value.Take(1))
{
var likeResult = await _instaApi.LikeMediaAsync(media.InstaIdentifier);
var postResult = await _instaApi.CommentMediaAsync(media.InstaIdentifier, textBox1.Text);
}
}
}
字符串值的示例是“username”。