[xsd-users] Re: Help me: VC pro and VC express generate different
XML
James Mei
jxmei3 at gmail.com
Fri Oct 16 20:10:07 EDT 2009
Hi Boris
I just found out that ix and sGroup is part of the schema as optional items.
The strange part for VC++ express and VC++ Pro 2008 is that:
Same source code but one compiler program produces those attributes (VC++
pro) and one does not (VC++ express). BTW, the original xml file does not
have those attributes.
I also found out that the strange number at the back ix="3452816845", is the
actual pointer value of the attribute.
Any idea ?
///////////////////////////////////////////////////////Source
int _tmain(int argc, _TCHAR* argv[])
{
try
{
using namespace SC_SCL;
auto_ptr<SCL> h (SCL_ (argv[1], xml_schema::flags::dont_validate));
ofstream outfile(argv[2], ios::out);
SCL_(outfile, *h);
}
catch (const xml_schema::exception& e)
{
cerr << e << endl;
return 1;
}
}
//////////////////////////////
Also notice the constructor of the xsd class (SCL) does not take wchar_t* as
input filename. It has to be char *. Is there anyway to make it unicode
compatible ?
Cheers
James
On Fri, Oct 16, 2009 at 5:03 PM, James Mei <jxmei3 at gmail.com> wrote:
> Hi Boris
>
>>
>> > ix="3452816845", sGroup="3452816845" are not part of the schema and do
>> > not exist in the program output generated by vc express 2008.
>>
>> They are part of the schema.
>>
>
> If it is part of the schema, then VC express should generate this entries
> as well. But it has no where exists in the xsd file.
>
>>
>> > Also, the decimal value of 3452816845 is HEX 0xCDCDCDCD, does it mean
>> > anything ?
>>
>> It is most likely garbage. I suspect that you are trying this with XSD
>> source code that you have modified. Can you try it on the standard XSD
>> distribution without any modifications? Double check that the include
>> paths in VC++ point to the unmodified libxsd.
>>
>
> I have now regenerated the source file, but the same thing happened.
> However, the program compiled with BCB2009 produces one sGroup attribute in
> one of the TAG. None exist in the program compiled by VC express 2008. Lots
> of those ix, sGroup entries in the program compiled by VC pro.
>
> Any idea ?
>
> Cheers
> James
>
More information about the xsd-users
mailing list