I think because of this the images (.rximgres file) made to recognize some elements do not are not recreated/refreshed anymore. Does someone know how to solve this? Double clicking the message redirects to the following file but I don't know what's wrong:The "CreateImageResources" task failed unexpectedly.
System.Xml.XmlException: '', hexadecimal value 0x1E, is an invalid character. Line 4054, position 285.
at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.Throw(String res, String[] args)
at System.Xml.XmlTextReaderImpl.ThrowInvalidChar(Char[] data, Int32 length, Int32 invCharPos)
at System.Xml.XmlTextReaderImpl.ParseAttributeValueSlow(Int32 curPos, Char quoteChar, NodeData attr)
at System.Xml.XmlTextReaderImpl.ParseAttributes()
at System.Xml.XmlTextReaderImpl.ParseElement()
at System.Xml.XmlTextReaderImpl.ParseElementContent()
at System.Xml.XmlTextReaderImpl.Read()
at System.Xml.XmlTextReader.Read()
at Ranorex.Core.Repository.ElementRepository.RepositoryXmlReader..ctor(String repoFilePath)
at Ranorex.Core.Repository.ElementRepository.UpdateImageResource(String repoFilePath, String outputDirectory)
at Ranorex.MSBuildTasks.CreateImageResources.Execute()
at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult) (MSB4018) - C:\Program Files (x86)\MSBuild\Ranorex5\Ranorex.MSBuild.Targets:1
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<UsingTask
TaskName="Ranorex.MSBuildTasks.GetRxSearchPaths"
AssemblyFile="$(MSBuildExtensionsPath)\Ranorex5\Ranorex.MSBuildTasks.exe"/>
<UsingTask
TaskName="Ranorex.MSBuildTasks.CreateImageResources"
AssemblyFile="$(MSBuildExtensionsPath)\Ranorex5\Ranorex.MSBuildTasks.exe"/>
<PropertyGroup>
<InitRxSearchPathsDependsOn>$(ResolveAssemblyReferencesDependsOn)</InitRxSearchPathsDependsOn>
<ResolveAssemblyReferencesDependsOn>InitRxSearchPaths</ResolveAssemblyReferencesDependsOn>
<BuildDependsOn>CreateImageResources;$(BuildDependsOn)</BuildDependsOn>
<CleanDependsOn>$(CleanDependsOn);RemoveImageResources</CleanDependsOn>
</PropertyGroup>
<Target Name="InitRxSearchPaths" DependsOnTargets ="$(InitRxSearchPathsDependsOn)">
<GetRxSearchPaths SearchPaths="$(AssemblySearchPaths)">
<Output TaskParameter="SearchPaths" PropertyName="AssemblySearchPaths"/>
</GetRxSearchPaths>
</Target>
<Target Name="RemoveImageResources">
<ItemGroup>
<Content Remove="RepositoryImages\*.rximgres"/>
</ItemGroup>
<RemoveDir Directories="$(OutDir)RepositoryImages" ContinueOnError="true"/>
<RemoveDir Directories="RepositoryImages" ContinueOnError="true"/>
</Target>
<ItemGroup>
<Content Include="RepositoryImages\*.rximgres" >
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
<Target Name="CreateImageResources">
<ItemGroup>
<AllItems Include="@(None);@(Content)" Condition="'%(Extension)'=='.rxrec' or '%(Extension)'=='.rxrep'"/>
</ItemGroup>
<RemoveDuplicates Inputs="@(AllItems)">
<Output TaskParameter="Filtered" ItemName="FilteredItems"/>
</RemoveDuplicates>
<CreateImageResources FileItems="@(FilteredItems)"
OutputDirectory="$(MSBuildProjectDirectory)"
ContinueOnError="true"/>
<ItemGroup>
<Content Include="RepositoryImages\*.rximgres" >
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
</Target>
</Project>