.net 오류 이거 어디를 봐야하나요..

visual studio가 설치 된 제 pc는 문제가없는데
다른 pc에서 프로그램을 실행할때 실행이안됩니다.
아래 내용은 윈도우 이벤트뷰어에 찍힌 로그입니다.
닷넷이 기존에 4.0이었다가 4.8로 올리고 정상적으로 빌드가 되서 문제가 없다 생각했는데
이런 문제가 생겼네요… 어디부터 확인을해야할까요?

응용 프로그램: RDSYS.exe
Framework 버전: v4.0.30319
설명: 처리되지 않은 예외로 인해 프로세스가 종료되었습니다.
예외 정보:System.IO.DirectoryNotFoundException
위치: System.IO.__Error.WinIOError(Int32, System.String)
위치: System.IO.FileStream.Init(System.String, System.IO.FileMode, System.IO.FileAccess, Int32, Boolean, System.IO.FileShare, Int32, System.IO.FileOptions, SECURITY_ATTRIBUTES, System.String, Boolean, Boolean, Boolean)
위치: System.IO.FileStream…ctor(System.String, System.IO.FileMode, System.IO.FileAccess, System.IO.FileShare)
위치: System.Windows.Media.Imaging.BitmapDecoder.SetupDecoderFromUriOrStream(System.Uri, System.IO.Stream, System.Windows.Media.Imaging.BitmapCacheOption, System.Guid ByRef, Boolean ByRef, System.IO.Stream ByRef, System.IO.UnmanagedMemoryStream ByRef, Microsoft.Win32.SafeHandles.SafeFileHandle ByRef)
위치: System.Windows.Media.Imaging.BitmapDecoder.CreateFromUriOrStream(System.Uri, System.Uri, System.IO.Stream, System.Windows.Media.Imaging.BitmapCreateOptions, System.Windows.Media.Imaging.BitmapCacheOption, System.Net.Cache.RequestCachePolicy, Boolean)
위치: System.Windows.Media.Imaging.BitmapFrame.CreateFromUriOrStream(System.Uri, System.Uri, System.IO.Stream, System.Windows.Media.Imaging.BitmapCreateOptions, System.Windows.Media.Imaging.BitmapCacheOption, System.Net.Cache.RequestCachePolicy)
위치: System.Windows.Media.ImageSourceConverter.ConvertFrom(System.ComponentModel.ITypeDescriptorContext, System.Globalization.CultureInfo, System.Object)
위치: System.Windows.Baml2006.TypeConverterMarkupExtension.ProvideValue(System.IServiceProvider)
위치: MS.Internal.Xaml.Runtime.ClrObjectRuntime.CallProvideValue(System.Windows.Markup.MarkupExtension, System.IServiceProvider)

예외 정보:System.Windows.Markup.XamlParseException
위치: System.Windows.Markup.WpfXamlLoader.Load(System.Xaml.XamlReader, System.Xaml.IXamlObjectWriterFactory, Boolean, System.Object, System.Xaml.XamlObjectWriterSettings, System.Uri)
위치: System.Windows.Markup.WpfXamlLoader.LoadBaml(System.Xaml.XamlReader, Boolean, System.Object, System.Xaml.Permissions.XamlAccessLevel, System.Uri)
위치: System.Windows.Markup.XamlReader.LoadBaml(System.IO.Stream, System.Windows.Markup.ParserContext, System.Object, Boolean)
위치: System.Windows.Application.LoadBamlStreamWithSyncInfo(System.IO.Stream, System.Windows.Markup.ParserContext)
위치: System.Windows.Application.LoadComponent(System.Uri, Boolean)
위치: System.Windows.Application.DoStartup()
위치: System.Windows.Application.<.ctor>b__1_0(System.Object)
위치: System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
위치: System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
위치: System.Windows.Threading.DispatcherOperation.InvokeImpl()
위치: System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
위치: MS.Internal.CulturePreservingExecutionContext.CallbackWrapper(System.Object)
위치: System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
위치: System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
위치: System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
위치: MS.Internal.CulturePreservingExecutionContext.Run(MS.Internal.CulturePreservingExecutionContext, System.Threading.ContextCallback, System.Object)
위치: System.Windows.Threading.DispatcherOperation.Invoke()
위치: System.Windows.Threading.Dispatcher.ProcessQueue()
위치: System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
위치: MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
위치: MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
위치: System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
위치: System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
위치: System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
위치: MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)
위치: MS.Win32.UnsafeNativeMethods.DispatchMessage(System.Windows.Interop.MSG ByRef)
위치: System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame)
위치: System.Windows.Threading.Dispatcher.PushFrame(System.Windows.Threading.DispatcherFrame)
위치: System.Windows.Application.RunDispatcher(System.Object)
위치: System.Windows.Application.RunInternal(System.Windows.Window)
위치: System.Windows.Application.Run(System.Windows.Window)
위치: System.Windows.Application.Run()
위치: RDSYS.App.Main()

1개의 좋아요

엇…소스코드가 없어서 정확한 판단은 어렵지만…

System.IO.DirectoryNotFoundException

이 Exception으로 보아선 디렉토리 관련된 부분인 거 같아요 코드쪽에서 한번 확인해보시는것도 좋을 것 같습니다.

근데 Framework버전 올리셨다는데 …v4.0.30319 으로 되어있고…

음 혹시 다른 PC에 닷넷 프레임워크 배포 버전 4.8이 설치되지 않아서 그런건아닐까요?

1개의 좋아요

디버그 쪽에있는 파일을 그대로 복사해서 다른 pc에서 실행해봤었습니다.
대상 pc는 윈도 11 설치한 기본상태이고
윈도우 기능봤을때에는 4.8이 전부 체크는 아니지만 일부 체크가되있었는데
그게 문제였을까요??
System.IO.DirectoryNotFoundException
이부분도 의문이긴한데… 디버그에 없는 파일이라…

1개의 좋아요

파일도 그대로 복사 하셨다면
우선 프레임워크 버전이 확실하신지부터 먼저확인을…!

여기 참고해보시고 결과를 알려주세요!

1개의 좋아요

일단 예외 메시지로만 봤을 때는 XAML에서 사용하는 이미지 경로에서 디렉토리가 존재하지 않아 발생한 듯 한데요, 외부 이미지를 사용하는 XAML을 찾아보시면 답이 나오지 않을까 합니다.

2개의 좋아요

알려주신 닷넷 버전 확인하는거로 확인해보니
레지스트리 편집기에서 v4 아래 Full 디렉토리안에 하위 항목이 있는거로봐서 4.5이상 설치되어있습니다.

이러면 사용pc에 닷넷문제는 아닌거같아요

2개의 좋아요

아 이미지 경로말씀하셔서 테스트한다고 절대경로 넣어논게 생각났습니다…
이거 수정하니까 실행이되네요 감사합니다.

4개의 좋아요