TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
vikash kumar tiwari
NA
6
2.1k
how to generate rss feed in asp dotnet c#
Oct 2 2015 1:02 AM
i try to generate rss feed using this code ,but it give me a exception at run time as "
Cannot attach the file 'c:\users\vikash123\documents\visual studio 2013\Projects\Sample_WebformApplication_RSS\Sample_WebformApplication_RSS\App_Data\aspnet-Sample_WebformApplication_RSS-20150928114944.mdf' as database 'aspnet-Sample_WebformApplication_RSS-20150928114944'."
my code as following
protected void Page_Load(object sender, EventArgs e)
{
string connectionstring = ConfigurationManager.ConnectionStrings["DefaultConnection"].ConnectionString;
SqlConnection sqlcon = new SqlConnection();
sqlcon.ConnectionString = connectionstring;
SqlCommand cmd = new SqlCommand();
cmd.Connection = sqlcon;
cmd.CommandType = CommandType.Text;
cmd.CommandText = "SELECT TOP 10 * FROM sample";
sqlcon.Open();
rep.DataSource = cmd.ExecuteReader();
rep.DataBind();
sqlcon.Close();
}
Reply
Answers (
2
)
DataTable Rows visible false
how to get view count of YouTube video?