Hi..
i know this post is very old. but I want the similar requirement. How to add the validation when the file size attached is greater than 10kb in info-path form. I am using Infopath form 2013 and SharePoint 2016 on premise. I have tried the base 64 coding by using string length and the javascript on new item page. But both didnot worked. ...