are you wanting to remove <key>key9</key>
or
<string>string6</string>
or both
<key>key9</key>
and
<string>string6</string> ??????
here is what you wanted to do not sure you will understand the code though
or
<string>string6</string>
or both
<key>key9</key>
and
<string>string6</string> ??????
here is what you wanted to do not sure you will understand the code though
IXml x._create
x.FromFile("$desktop$\plist_file\file.plist")
int t tt
ARRAY(IXmlNode) a b; int i
x.RootElement.GetAll(0 a)
for i 0 a.len
,IXmlNode n=a[i]
,if(!StrCompare(n.Value "key20"))
,,t=1
,if(!StrCompare(n.Value "key7"))
,,n=n.Next
,,if(!StrCompare(n.Name "false"))
,,,n.Name="true"
,if(!StrCompare(n.Value "key9"))
,,x.Delete(n);; remove <key>key9</key>
,,n=a[i+1]
,,if(!StrCompare(n.Name "string"))
,,,x.Delete(n);; remove <string>string6</string>
if(t!=1)
,x.Path("plist/dict/dict").GetAll(0 b)
,for i 0 b.len
,,sel b[i].Name
,,,case "key"
,,,if(!StrCompare(b[i].Value "key5"))
,,,,IXmlNode iafter
,,,,iafter=b[i+1]
,,,,b[i].Parent.Insert(iafter "string" "string20")
,,,,b[i].Parent.Insert(iafter "key" "key20")
x.ToString(_s)
out _s