Hi here is the solution use these code
using (MemoryStream input = new MemoryStream(renderedBytes))
{
using (MemoryStream output = new MemoryStream())
{
PdfReader reader = new PdfReader(input);
reader.AddViewerPreference(PdfName.HIDEMENUBAR, PdfName.NONE);
PdfEncryptor.Encrypt(reader, output, true, null, null, PdfWriter.ALLOW_PRINTING | PdfWriter.AllowPrinting | PdfWriter.ENCRYPTION_AES_128 | PdfWriter.CenterWindow);
renderedBytes = output.ToArray();
Response.ContentType = "application/pdf";
}
}"i