Page 1 of 1

Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Mon Oct 07, 2019 7:37 pm
by andy.simpson
Hi All,

I have just upgraded Ranorex to the latest 9.1.2 version but am getting a build error saying that I need to install the lastest SDK or targeting pack for this version. I have downloaded this from the Microsoft website but adding this in the references tab does not appear to resolve the issue, can someone give me some pointers as to how this is done.

Any help would be greatly appreciated, I have uploaded a screenshot of the build error

Many thanks

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Mon Oct 07, 2019 9:42 pm
by odklizec
Hi,

Are you sure you have installed SDK for .NET Framework 4.6.2? This appears to be a required package for some systems. See system requirements here...
https://www.ranorex.com/help/latest/ran ... uirements/

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Tue Oct 08, 2019 8:41 am
by andy.simpson
Yeah that's all been installed, as picture attached, how do I check and change which version Ranorex is targeted towards?

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Tue Oct 08, 2019 8:53 am
by andy.simpson
I've also run Microsoft .net verification tool which shows that its installed on my VM

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Tue Oct 08, 2019 8:54 am
by odklizec
Hi,

You can check project targeting in Project settings:
ProjectProperties.png
Anyway, I think this kind of issue should be discussed directly with Ranorex support. There seems to be something wrong in your system or installed .Net libs? Have you tried Ranorex and your solution on another PC?

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Tue Oct 08, 2019 9:04 am
by andy.simpson
Yeah it is correctly targeting 4.6.2 in the compiling options, I'll refer it to Ranorex support and see if they can help, I'll post on here how I get on

Thanks for your reply's appreciate it

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Tue Oct 08, 2019 3:36 pm
by andy.simpson
OK so after some assistance from Ranorex support I have resolved the issue, they were not able to reproduce the issue so it must have been environmental. I followed through the steps below and this resulted in being able to build the solutions successfully

1. Uninstall Ranorex Studio.
2. Uninstall the .Net 4.6.2 SDK.
3. Reboot your computer.
4. Reinstall SDK
5. Install latest version of Ranorex

It should be noted that I use visual studio 2017 as CI and re-mapped with a fresh workspace although this was not a recommended step

Hopefully this helps anyone else who has a similar issue

Re: Build error regarding missing 4.6.2 assemblies following upgrade

Posted: Wed Nov 06, 2019 5:43 pm
by rragsac
Upgrading to 9.2, I had the same issue with Visual Studio 2017 installed. I was upgrading from an older version of Ranorex.

The prerequisite executable gave me a setup error saying .NET 4.6.2 was already installed. After I installed the Ranorex 9.2 update, Ranorex could never find the 4.6.2 assemblies, because the .Net 4.6.2 needed to be registered for Ranorex. My Compiling options had ".NET 4.6.2 Framework" selected.

Because Visual Studio 2017 is using .NET 4.7.2, installing the prerequisite.exe cannot be completed, because the prerequisite executable must be finding what VS2017 already installed.

I did try uninstalling Ranorex Studio, but I never had the .NET 4.6.2 SDK listed in Add/Remove Programs, because it was installed as part of VS2017 SDK.

The workaround I did was to:
1. Uninstall VS2017
2. Install the prerequisite.exe
3. Install Ranorex update
4. Reinstall VS2017 (I deselected the install option for .Net 4.6.2 Framework, since I would use 4.7.2 in VS development.)

Regards