Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Search for file at run-time
Message
De
06/10/2004 12:06:28
 
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00949224
Message ID:
00949229
Vues:
8
Einar,

Do you mean having the user select a file? If so, something like this would work:
System.Windows.Forms.OpenFileDialog oSelectFile = new System.Windows.Forms.OpenFileDialog();
DialogResult dr = oSelectFile.ShowDialog();

if(dr == DialogResult.OK) 
{
  // oSelectFile.FileName contains the name of the file selected.
}
~~Bonnie

>How would I go about searching for a file on My Computer at run time?
>I might want to narrow the search down to only local drives, in that case how can I get an array or collection of local drives?
>
>Thanks,
>Einar
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform