PROBLEM:
Do you know something in .NET that can convert my text(string) and return an image type? Like .Net “Convert” Class does but it doesnt support image conversion.
I mean.. just like passing a file information (filename and Path) as parameters and return image(Bitmap) to display.
Do I really have to code this manually?
SCENARIO:
I successfully collect some list of image files in a directory(From Flash Drive or in local drive) and want to display those as an actual image.
Hope my problem is clear.
Depending to whether you’re using WinForms or WPF, you could use
System.Drawing.ImageorSystem.Windows.Media.ImageSource.You can’t convert a string to an on-screen image. You HAVE to load it in another component. For example,
Imagehas a staticFromFile(string filepath)method that loads the image and makes it available for display.