1. Subbiya Vasumoorthy
  2. SnapDevelop
  3. Friday, 15 November 2024 17:47 PM UTC

Hi Team,
I'm building a class library using .net core 3.1 in which I need to access windows registry keys for validating acrobat installation, I'm trying to use below code but received an error

using Microsoft.Win32;


Error:
"CS1069 The type name 'RegistryView' could not be found in the namespace 'Microsoft.Win32'. This type has been forwarded to assembly 'Microsoft.Win32.Registry, Version=4.1.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' Consider adding a reference to that assembly.


"
Trying to add it in project references, but clicking on COM, it throws me following error

Please help me to resolve this error

Thanks,
Subbiya

Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Friday, 15 November 2024 21:15 PM UTC
  2. SnapDevelop
  3. # 1

Is the app running as admin?  Admin rights required to access windows registry.  Also, we recommend using at least .NET 6.  .NET 3.1 is very old.

Comment
There are no comments made yet.
Subbiya Vasumoorthy Accepted Answer Pending Moderation
  1. Tuesday, 19 November 2024 16:13 PM UTC
  2. SnapDevelop
  3. # 2

Hi Team,
We cannot use .net version 6.0 for some reason, but i have installed Microsoft.Win32.Registry nuget package, do i need to use "Generate NuGet package on build" option under Package -> General. ?

Comment
  1. Armeen Mazda @Appeon
  2. Tuesday, 19 November 2024 16:55 PM UTC
I would recommend asking your question also on a Microsoft forum since this is not PowerBuilder specific. You may get more responses/help on Microsoft forum for .NET/COM issues.
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.