Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

wpf load file content

OpenFileDialog openFileDialog = new OpenFileDialog
{
    Filter = "TXT file (*.txt)|*.txt"
};
string fileContent = "";
            
if (openFileDialog.ShowDialog() == true){
    fileContent = System.IO.File.ReadAllText(openFileDialog.FileName);
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #wpf #load #file #content
ADD COMMENT
Topic
Name
3+7 =