Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System.UnauthorizedAccessException: Attempted to perform an unauthorized operation. #407

Closed
Ovear opened this issue Sep 13, 2017 · 3 comments

Comments

@Ovear
Copy link

Ovear commented Sep 13, 2017

I can not set SyncTrayzor automatically start on login due the the security software.
SyncTrayzor stop responding after this error. It seems that it shouldn't be no responding.

Version: 1.1.18.0; Variant: Portable; Arch: Amd64
Path: D:\SyncTrayzorPortable-x64\SyncTrayzor.exe
System.UnauthorizedAccessException: Attempted to perform an unauthorized operation.
   at Microsoft.Win32.RegistryKey.Win32Error(Int32 errorCode, String str)
   at Microsoft.Win32.RegistryKey.SetValue(String name, Object value, RegistryValueKind valueKind)
   at SyncTrayzor.Services.AutostartProvider.SetAutoStart(AutostartConfiguration config) in C:\projects\synctrayzor\src\SyncTrayzor\Services\AutostartProvider.cs:line 222
   at SyncTrayzor.Pages.Settings.SettingsViewModel.Save() in C:\projects\synctrayzor\src\SyncTrayzor\Pages\Settings\SettingsViewModel.cs:line 379
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at Stylet.Xaml.ActionBase.InvokeTargetMethod(Object[] parameters) in c:\projects\stylet\Stylet\Xaml\ActionBase.cs:line 201
   at MS.Internal.Commands.CommandHelpers.CriticalExecuteCommandSource(ICommandSource commandSource, Boolean userInitiated)
   at System.Windows.Controls.Primitives.ButtonBase.OnClick()
   at System.Windows.Controls.Button.OnClick()
   at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
   at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
   at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
@jebeld17
Copy link

jebeld17 commented Oct 8, 2017

#412 and #410.
Are any of these similar to your errors?

@canton7
Copy link
Owner

canton7 commented Oct 8, 2017

No this is a different issue.

@canton7
Copy link
Owner

canton7 commented Feb 28, 2018

Looks like you've got a very strange setup, where we were allowed to write to the registry key on startup (we do a check to see whether we have permission to write), but by the time you came to edit your settings we'd been denied access.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants