My requirent is "how to bind textfile data into listbox using silverlight".....By using openfile dialog we can do but i want without using openfile dialog concept....plz if it possible send me direct code because its on urgent requirement.
Loading
My requirent is "how to bind textfile data into listbox using silverlight".....By using openfile dialog we can do but i want without using openfile dialog concept....plz if it possible send me direct code because its on urgent requirement.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Shubham SaxenaRank #278 · 8.9K reputationPosted Jul 27, 2012, 1:59 PM EDT
Cheers.
ravi kiran102 reputationPosted Jul 29, 2012, 9:11 PM EDT
try { string fileData;
IsolatedStorageFile file = IsolatedStorageFile.GetUserStoreForApplication();
using (IsolatedStorageFileStream isoStream = new IsolatedStorageFileStream("ravi10.txt", FileMode.Open, file))
{ using (StreamReader reader = new StreamReader(isoStream))
{ fileData = reader.ReadToEnd(); } }
listBox1.ItemsSource = fileData.Split(' '); }
catch (Exception ex)
{ MessageBox.Show(ex.Message); }
please if it possible can u do it and send me code because its very urgent requirement for me.please help me.
Jaganathan BantheswaranRank #170 · 14.1K reputationPosted Aug 1, 2012, 9:59 PM EDT
What is the Error ?
[EDIT]:
You can try this version:
using (var store = IsolatedStorageFile.GetUserStoreForApplication())