With a few rules in Facebook catalog manager, we can use same feed file in Facebook catalog. But recently facebook updated some rules for feed file because of that we are getting this error when we try to upload file
Error = "your XML data feed file is too long and exceeds our size limit of 5,242,880 bytes (5 MB) or characters."
This error occurs due to, XML document doesn't use indent when generating XML file & if you open it in notepad then all text shown in one line.
so I resolved it by applying this solution
var settings = new XmlWriterSettings { Encoding = Encoding.UTF8, Indent = true // newly added line };
After this modification even if you open a file in notepad, you will see single property only in each line. Also, facebook accepts this file for feed too.
1 more important thing is, file size increased from 20 MB to 23 MB in my case.
Hi,
With a few rules in Facebook catalog manager, we can use same feed file in Facebook catalog. But recently facebook updated some rules for feed file because of that we are getting this error when we try to upload file
Error = "your XML data feed file is too long and exceeds our size limit of 5,242,880 bytes (5 MB) or characters."
This error occurs due to, XML document doesn't use indent when generating XML file & if you open it in notepad then all text shown in one line.
so I resolved it by applying this solution
var settings = new XmlWriterSettings { Encoding = Encoding.UTF8, Indent = true // newly added line };
Stackoverflow Link
After this modification even if you open a file in notepad, you will see single property only in each line. Also, facebook accepts this file for feed too.
1 more important thing is, file size increased from 20 MB to 23 MB in my case.
Thanks.