السلام عليكم
اولا اخى سيتوجب قراءة ال RSS news
باستخدام هذا الكود
كود:
using System.Xml;
// First clear of any previous items in the ListView
lstNews.Items.Clear();
this.Cursor = Cursors.WaitCursor;
// Create a new XmlTextReader from the specified URL (RSS feed)
rssReader = new XmlTextReader(txtUrl.Text);
rssDoc = new XmlDocument();
// Load the XML content into a XmlDocument
rssDoc.Load(rssReader);
// Loop for the <rss> tag
for (int i = 0; i < rssDoc.ChildNodes.Count; i++)
{
// If it is the rss tag
if (rssDoc.ChildNodes[i].Name == "rss")
{
// <rss> tag found
nodeRss = rssDoc.ChildNodes[i];
}
}
// Loop for the <channel> tag
for (int i = 0; i < nodeRss.ChildNodes.Count; i++)
{
// If it is the channel tag
if (nodeRss.ChildNodes[i].Name == "channel")
{
// <channel> tag found
nodeChannel = nodeRss.ChildNodes[i];
}
}
// Set the labels with information from inside the nodes
lblTitle.Text = "Title: " + nodeChannel["title"].InnerText;
lblLanguage.Text = "Language: " + nodeChannel["language"].InnerText;
lblLink.Text = "Link: " + nodeChannel["link"].InnerText;
lblDescription.Text = "Description: " + nodeChannel["description"].InnerText;
// Loop for the <title>, <link>, <description> and all the other tags
for (int i = 0; i < nodeChannel.ChildNodes.Count; i++)
{
// If it is the item tag, then it has children tags which we will add as items to the ListView
if (nodeChannel.ChildNodes[i].Name == "item")
{
nodeItem = nodeChannel.ChildNodes[i];
// Create a new row in the ListView containing information from inside the nodes
rowNews = new ListViewItem();
rowNews.Text = nodeItem["title"].InnerText;
rowNews.SubItems.Add(nodeItem["link"].InnerText);
lstNews.Items.Add(rowNews);
}
}
this.Cursor = Cursors.Default;
تجد الكود وشرحه
هنا
بعد ذلك تقوم بارسال البيانات الى البيك عن طريق السيريال بورت.
ملحوظة حاول ان تجعل الكمبيوتر يقوم بكل العمليات اما الميكرو فيقوم بالعرض فقط حتى المصفوفات الخاصة بالماتريكس قم باضافتها الى برنامج الفيجوال .
عليك ان تبدأ بكتابة الاكواد وعندما تواجهك اى مشكلة فلا تتردد بالاستفسار وستجد من اعضاء القرية من يساعدك ان شاء الله.
اتمنى ان اكون قد افدتك.
بالتوفيق.