c# 4.0 - How can I save the picture on image control in wpf? -


i have simple wpf application wia.my app has image control... wondering how can save scanned picture on hard disk?

depends on type of image.source, assuming have bitmapsource in article should along lines:

var encoder = new pngbitmapencoder(); encoder.frames.add(bitmapframe.create((bitmapsource)image.source)); using (filestream stream = new filestream(filepath, filemode.create))     encoder.save(stream); 

Comments

Popular posts from this blog

haskell - Using filter on an item in a list? -

tomcat6 - Exception when stopping container for a with Spring + Quartz + Tomcat web application -

c# - Binding attached property to IEnumerable -