I have this XML file where I want to change the value of fit-to-largest from false to true. Like this:
<Hmi.Screen.TextField Name="Text Field_1" AggregationName="ScreenItems" ID="31">
<ObjectList>
<Hmi.Screen.Property Name="Layer" AggregationName="Properties" ID="77">
<AttributeList>
<Value>0</Value>
</AttributeList>
</Hmi.Screen.Property>
<Hmi.Screen.Property Name="Left" AggregationName="Properties" ID="78">
<AttributeList>
<Value>264</Value>
</AttributeList>
</Hmi.Screen.Property>
<Hmi.Screen.Property Name="Top" AggregationName="Properties" ID="79">
<AttributeList>
<Value>48</Value>
</AttributeList>
</Hmi.Screen.Property>
<Hmi.Screen.Property Name="FitToLargest" AggregationName="Properties" ID="84">
<AttributeList>
<Value>false</Value>
</AttributeList>
</Hmi.Screen.Property>
</ObjectList>
</Hmi.Screen.TextField>
From this code I want to change this part form this:
<Hmi.Screen.Property Name="FitToLargest" AggregationName="Properties" ID="84">
<AttributeList>
<Value>false</Value>
</AttributeList>
</Hmi.Screen.Property>
to this:
<Hmi.Screen.Property Name="FitToLargest" AggregationName="Properties" ID="84">
<AttributeList>
<Value>true</Value>
</AttributeList>
</Hmi.Screen.Property>
(false becomes true)
I want to change this by loading the XML file (I know how) and then find and replace the false to true.
This part of code is found in every textfield, but with a different value for the attribute ID. I want to change it for every textfield.