Thanks for contacting support.
I am afraid that Aspose.PDF does not provide any direct method to determine file size of page size of a PDF document. A feature request as PDFNET-43073 is already logged in our issue tracking system for the sake of implementation. As soon as the feature is available, we will surely inform you. Please spare us little time.
Furthermore, you can use following workaround to get size of page before making compression decision:
Document inputPdfDocument = new Document(dataDir + "input.pdf");
Document doc = new Document();
// Add page which size is required to be determined
MemoryStream ms = new MemoryStream();
long filesize = ms.Length;
// Compare the filesize with MBs
if ((filesize / (1024 * 1024)) < 46)
// Do stuff