Page 1 of 1

9.0.1 - csproj now getting several new duplicate entries

Posted: Tue Apr 23, 2019 10:07 pm
by dhale
Anyone else seeing this kind of an issue?
Any ideas why the duplicate entries are being created?
Before 9.0.1 upgrade this is what my 8.3 csproj looked like:

<PropertyGroup>
<ProjectGuid>{07F903E1-8631-442C-B239-1FEDF5A27F2A}</ProjectGuid>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<OutputType>Library</OutputType>
<RootNamespace>Rx.RxCommon</RootNamespace>
<AssemblyName>Rx.RxCommon</AssemblyName>
<RanorexVersion>8.3</RanorexVersion>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkProfile />
<AllowUnsafeBlocks>False</AllowUnsafeBlocks>
<NoStdLib>False</NoStdLib>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<RanorexTargetsPath>$(MSBuildProgramFiles32)\MSBuild\Ranorex$(RanorexVersion)\Ranorex.MSBuild.Targets</RanorexTargetsPath>
</PropertyGroup>


After I upgraded to 9.0.1 several of my csproj files now contain the following, and its growing
<PropertyGroup>
<ProjectGuid>{07F903E1-8631-442C-B239-1FEDF5A27F2A}</ProjectGuid>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<OutputType>Library</OutputType>
<RootNamespace>Rx.RxCommon</RootNamespace>
<AssemblyName>Rx.RxCommon</AssemblyName>
<RanorexVersion>9.0</RanorexVersion>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkProfile />
<AllowUnsafeBlocks>False</AllowUnsafeBlocks>
<NoStdLib>False</NoStdLib>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<RANOREX_BIN_PATH Condition=" '$(RANOREX_BIN_PATH)' == '' ">$([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\SOFTWARE\Ranorex\Studio', 'InstallDir', null, RegistryView.Registry64, RegistryView.Registry32))\Bin</RANOREX_BIN_PATH>
<RanorexTargetsPath>$(RANOREX_BIN_PATH)\Ranorex.MSBuild.Targets</RanorexTargetsPath>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
</PropertyGroup>

Re: 9.0.1 - csproj now getting several new duplicate entries

Posted: Wed Apr 24, 2019 12:12 pm
by RobinHood42
Did you already re-install (+re-boot) Ranorex? Sounds like an installation mess.

Re: 9.0.1 - csproj now getting several new duplicate entries

Posted: Wed Apr 24, 2019 4:30 pm
by dhale
Reinstalled, rebooted and still having an issue.

When I clean, then build within Ranorex Studio, the entries are being added.
Subsequent Clean/Rebuild didn't add new entries until I shut down and restarted Ranorex studio.

After opening Ranorex studio again, selecting the sln from the "Recent solutions" area created one entry in one of the csproj files.
cleaning then caused the other two to get new entries.

So in a nutshell: Closing down Studio and reopening Studio followed by a clean and build continues to add new entries to the included csproj files.

I'll email Support and see what they have to say about whats going on.

Re: 9.0.1 - csproj now getting several new duplicate entries

Posted: Thu Apr 25, 2019 12:54 pm
by Bytex
We had the same problem,... I try to remember what we did.

Open your solution and go to Build -> Set Platform -> ?
What platform is set for the solution.

We have x86 and when I remeber correct and you have the same platform set, then:
1) Make a backup copy of your csproj
2) Delete every <Platform Condition=" '$(Platform)' == '' ">x86</Platform> in you csproj.
3) Instead of the first: <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> with the AnyCPU, set this one to <Platform Condition=" '$(Platform)' == '' ">x86</Platform>

Your file should look then like this:

<PropertyGroup>
<ProjectGuid>{07F903E1-8631-442C-B239-1FEDF5A27F2A}</ProjectGuid>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<OutputType>Library</OutputType>
<RootNamespace>Rx.RxCommon</RootNamespace>
<AssemblyName>Rx.RxCommon</AssemblyName>
<RanorexVersion>9.0</RanorexVersion>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<TargetFrameworkProfile />
<AllowUnsafeBlocks>False</AllowUnsafeBlocks>
<NoStdLib>False</NoStdLib>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<RANOREX_BIN_PATH Condition=" '$(RANOREX_BIN_PATH)' == '' ">$([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\SOFTWARE\Ranorex\Studio', 'InstallDir', null, RegistryView.Registry64, RegistryView.Registry32))\Bin</RANOREX_BIN_PATH>
<RanorexTargetsPath>$(RANOREX_BIN_PATH)\Ranorex.MSBuild.Targets</RanorexTargetsPath>
</PropertyGroup>



I hope that I remembered correct that having two platforms in the csproj was the problem, then this will solve your little mess with the growing csproj :)

Re: 9.0.1 - csproj now getting several new duplicate entries

Posted: Thu Apr 25, 2019 8:32 pm
by dhale
Thanks for the info, I'll take a peek at it and see if it works.
Support did confirm this as a known issue that will be patched in a future release.

Re: 9.0.1 - csproj now getting several new duplicate entries

Posted: Fri May 10, 2019 12:20 pm
by Bytex
dhale wrote:
Thu Apr 25, 2019 8:32 pm
Thanks for the info, I'll take a peek at it and see if it works.
Support did confirm this as a known issue that will be patched in a future release.
You are welcome, I hope it worked for you too!
Would be nice if you can confirm this workaround helped or mention that it didn't worked for you, whatever the case is.
It helps other users, if you confirm this worked for you too, so they can relate to this workaround if they encounter the same problem.