반응형
private void GetImage()
{
OpenFileDialog openDialog = new OpenFileDialog();
if (openDialog.ShowDialog() == true)
{
if (File.Exists(openDialog.FileName))
{
ChangeImage changeimageWindow = new ChangeImage();
BitmapImage bitmapImage = new BitmapImage(new Uri(openDialog.FileName, UriKind.RelativeOrAbsolute));
ImageBox.Source = bitmapImage;
}
}
}
참고 : http://www.hoons.kr
반응형
'→ 개발 > WPF' 카테고리의 다른 글
| [WPF] C#코드로 버튼 생성 및 버튼 설정 (0) | 2010.07.09 |
|---|---|
| [WPF] 코드로 Label 생성하고 설정하기 (0) | 2010.07.07 |
| [WPF] C#코드로 도형 그릴때 선색 설정하기 (0) | 2010.07.07 |
| [WPF] 도형 좌표값 얻어오기 (0) | 2010.07.06 |
| [WPF] 슬라이더바 스크롤 설정하기 (0) | 2010.06.18 |