Rotativa 1.7.4 ActionAsPDF, Remove Navbar and Print buttonHow do you handle multiple submit buttons in ASP.NET MVC Framework?Remove Header and Footer using C#Prevent back buttonwkhtmltopdf Custom header and footers with ASP.NET MVCAutomatically Printing Page, then directing to next pageRemove header and footer when printing from WebBrowser controlUsing Rotativa results in a 'Could not load file or assembly' errorRotativa Issue printing RAW HTMLPrint Function using RotativaOpen Rotativa print dialog automatically

Does the Crossbow Expert feat's extra crossbow attack work with the reaction attack from a Hunter ranger's Giant Killer feature?

Can I say "fingers" when referring to toes?

Given this phrasing in the lease, when should I pay my rent?

How to leave product feedback on macOS?

Identifying "long and narrow" polygons in with PostGIS

How to make money from a browser who sees 5 seconds into the future of any web page?

Why is participating in the European Parliamentary elections used as a threat?

Animation: customize bounce interpolation

Would this string work as string?

What is this high flying aircraft over Pennsylvania?

Anime with legendary swords made from talismans and a man who could change them with a shattered body

Showing mass murder in a kid's book

Possible Eco thriller, man invents a device to remove rain from glass

Quoting Keynes in a lecture

Personal or impersonal in a technical resume

Isometric embedding of a genus g surface

Can I cause damage to electrical appliances by unplugging them when they are turned on?

Why the various definitions of the thin space ,?

I'm just a whisper. Who am I?

Can you identify this lizard-like creature I observed in the UK?

Limit max CPU usage SQL SERVER with WSRM

How can I, as DM, avoid the Conga Line of Death occurring when implementing some form of flanking rule?

How to test the sharpness of a knife?

Do you waste sorcery points if you try to apply metamagic to a spell from a scroll but fail to cast it?



Rotativa 1.7.4 ActionAsPDF, Remove Navbar and Print button


How do you handle multiple submit buttons in ASP.NET MVC Framework?Remove Header and Footer using C#Prevent back buttonwkhtmltopdf Custom header and footers with ASP.NET MVCAutomatically Printing Page, then directing to next pageRemove header and footer when printing from WebBrowser controlUsing Rotativa results in a 'Could not load file or assembly' errorRotativa Issue printing RAW HTMLPrint Function using RotativaOpen Rotativa print dialog automatically













0















I am trying to remove the navbar and print button from the page that I am trying to print. I attempted to use CustomSwitches but Rotativa does not appear to like them.



string customSwitches = "--disable-smart-shrinking --header-html 0 --footer-html 1";
var printForm = new ActionAsPdf("Receipt", new id = id ) PageSize = Rotativa.Options.Size.Legal, CustomSwitches = customSwitches ;
return printForm;


My view for reference: Print view.



What are some thoughts?










share|improve this question




























    0















    I am trying to remove the navbar and print button from the page that I am trying to print. I attempted to use CustomSwitches but Rotativa does not appear to like them.



    string customSwitches = "--disable-smart-shrinking --header-html 0 --footer-html 1";
    var printForm = new ActionAsPdf("Receipt", new id = id ) PageSize = Rotativa.Options.Size.Legal, CustomSwitches = customSwitches ;
    return printForm;


    My view for reference: Print view.



    What are some thoughts?










    share|improve this question


























      0












      0








      0








      I am trying to remove the navbar and print button from the page that I am trying to print. I attempted to use CustomSwitches but Rotativa does not appear to like them.



      string customSwitches = "--disable-smart-shrinking --header-html 0 --footer-html 1";
      var printForm = new ActionAsPdf("Receipt", new id = id ) PageSize = Rotativa.Options.Size.Legal, CustomSwitches = customSwitches ;
      return printForm;


      My view for reference: Print view.



      What are some thoughts?










      share|improve this question
















      I am trying to remove the navbar and print button from the page that I am trying to print. I attempted to use CustomSwitches but Rotativa does not appear to like them.



      string customSwitches = "--disable-smart-shrinking --header-html 0 --footer-html 1";
      var printForm = new ActionAsPdf("Receipt", new id = id ) PageSize = Rotativa.Options.Size.Legal, CustomSwitches = customSwitches ;
      return printForm;


      My view for reference: Print view.



      What are some thoughts?







      c# asp.net-mvc rotativa






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 7 at 8:06









      ArunPratap

      2,1312928




      2,1312928










      asked Mar 7 at 3:03









      AdrianAdrian

      52




      52






















          1 Answer
          1






          active

          oldest

          votes


















          1














          1. You can use --print-media-type custom switch.

          2. Apply the class no-print for your navbar div and button

          Then write your CSS like this



          @media print

          .no-print, .no-print *

          display: none !important;







          share|improve this answer























          • This worked like a charm, thank you!

            – Adrian
            Mar 7 at 16:03










          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55035405%2frotativa-1-7-4-actionaspdf-remove-navbar-and-print-button%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1














          1. You can use --print-media-type custom switch.

          2. Apply the class no-print for your navbar div and button

          Then write your CSS like this



          @media print

          .no-print, .no-print *

          display: none !important;







          share|improve this answer























          • This worked like a charm, thank you!

            – Adrian
            Mar 7 at 16:03















          1














          1. You can use --print-media-type custom switch.

          2. Apply the class no-print for your navbar div and button

          Then write your CSS like this



          @media print

          .no-print, .no-print *

          display: none !important;







          share|improve this answer























          • This worked like a charm, thank you!

            – Adrian
            Mar 7 at 16:03













          1












          1








          1







          1. You can use --print-media-type custom switch.

          2. Apply the class no-print for your navbar div and button

          Then write your CSS like this



          @media print

          .no-print, .no-print *

          display: none !important;







          share|improve this answer













          1. You can use --print-media-type custom switch.

          2. Apply the class no-print for your navbar div and button

          Then write your CSS like this



          @media print

          .no-print, .no-print *

          display: none !important;








          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 7 at 3:23









          Priyank PanchalPriyank Panchal

          519614




          519614












          • This worked like a charm, thank you!

            – Adrian
            Mar 7 at 16:03

















          • This worked like a charm, thank you!

            – Adrian
            Mar 7 at 16:03
















          This worked like a charm, thank you!

          – Adrian
          Mar 7 at 16:03





          This worked like a charm, thank you!

          – Adrian
          Mar 7 at 16:03



















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55035405%2frotativa-1-7-4-actionaspdf-remove-navbar-and-print-button%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          AWS Lex not identifying response if by a variable The 2019 Stack Overflow Developer Survey Results Are In Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern) The Ask Question Wizard is Live! Data science time! April 2019 and salary with experienceEnforcing custom enumeration in AWS LEX for slot valuesHow to give response based on user response in Amazon Lex?Intercepting AWS Lambda Response to a AWS Lex QueryLex chat bot error: Reached second execution of fulfillment lambda on the same utteranceamazon lex showing invalid responseLambda response send back to Lex slot?Response card in Amazon lexAmazon Lex - Lambda response return HTML to botHow can I solve 424 (Failed Dependency) (python) obtained from Amazon lex?

          Алба-Юлія

          Захаров Федір Захарович