<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
test7('1', "1") works because the simplest Content's element should
be <span class="code">IOString. <br>
<a class="moz-txt-link-freetext" href="http://www.erlang.org/doc/man/xmerl.html#export_simple-3">http://www.erlang.org/doc/man/xmerl.html#export_simple-3</a><br>
</span><br>
<br>
<div class="moz-cite-prefix">On 02/10/2015 11:46 AM, Lamchith M C
wrote:<br>
</div>
<blockquote
cite="mid:CAJwTqyDM5wHZLkXiunqzTy2-wvctH=6XJOY+pD7kywu3ra-UHQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div>I want to create Following xml .</div>
<div><br>
</div>
<div>
<div><?xml version="1.0"?></div>
<div><configuration></div>
<div><uid>1</uid></div>
<div>dif>1</dif></div>
<div></configuration></div>
</div>
<div><br>
</div>
<div>I am trying it with following code, but getting error.</div>
<div><br>
</div>
<div>serialize(Data) -></div>
<div> Xml = lists:flatten(xmerl:export_simple(Data,
xmerl_xml)),</div>
<div> io:format("~s~n", [Xml]).</div>
</div>
<div><br>
</div>
<div>test7(UId,DId) -><span class="" style="white-space:pre">
</span></div>
<div><span class="" style="white-space:pre"> </span></div>
<div> RootElem = {configuration,</div>
<div> [{uid, [UId]},{dif, [DId]}]},</div>
<div><span class="" style="white-space:pre"> </span></div>
<div><span style="white-space:pre"> </span>serialize([RootElem]).<span
class="" style="white-space:pre"> </span></div>
<div><span class="" style="white-space:pre"><br>
</span></div>
<div><span class="" style="white-space:pre">by calling
test7(1,1) </span></div>
<div><span class="" style="white-space:pre"><br>
</span></div>
<div><span style="white-space:pre">Please help.</span></div>
<div><br>
</div>
-- <br>
<div class="gmail_signature">
<div>Regards,</div>
<div>Lamchith</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
erlang-questions mailing list
<a class="moz-txt-link-abbreviated" href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a>
<a class="moz-txt-link-freetext" href="http://erlang.org/mailman/listinfo/erlang-questions">http://erlang.org/mailman/listinfo/erlang-questions</a>
</pre>
</blockquote>
<br>
</body>
</html>