foreach (string file in files)
{
int pos = file.LastIndexOf("\\"); string fname = file.Substring(pos + 1); listBox1.Items.Add(fname);
}
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 attend4days leftRegister
Amit GuptaRank #190 · 12.8K reputationPosted Nov 9, 2018, 8:40 PM EST
Amit GuptaRank #190 · 12.8K reputationPosted Nov 9, 2018, 7:37 PM EST
Amit GuptaRank #190 · 12.8K reputationPosted Nov 9, 2018, 7:19 PM EST
Sriram Ramki14 reputationPosted Nov 9, 2018, 7:24 PM EST
Amit GuptaRank #190 · 12.8K reputationPosted Nov 9, 2018, 7:28 PM EST
Sriram Ramki14 reputationPosted Nov 9, 2018, 7:31 PM EST
Sriram Ramki14 reputationPosted Nov 9, 2018, 7:53 PM EST