There is i have :
public void SaveBitmapSourceToFile(string filePath, BitmapSource img)
{
BitmapEncoder encoder = new JpegBitmapEncoder();
encoder.Frames.Add(BitmapFrame.Create(img));
using (FileStream fileStream = new FileStream(filePath, FileMode.Create))
{
encoder.Save(fileStream);
}
}
I need to detect encoder.Save()
finished so i can call another method that required my Jpg file