0

Suppose we have a web page in asp.net mvc and we have applied some style using css, now i want to print the entire web page or some part of the web page in the exact format in print dialog-box. Is there any way or API exist to print web page in ASP.NET MVC.

how can i achieve it.

1
  • 1
    It has nothing to do with mvc but with HTML and css, and you obviously don't use both mvc3 and mvc4. Commented Jan 31, 2013 at 16:14

1 Answer 1

1

This has nothing to do with ASP.NET MVC (which is server-side) and everything to do with CSS (which is client-side).

Take a look at the CSS Media Types available. Essentially what you want to do is create a separate style sheet (or separate rules in the same style sheet) which target the "Print" media type. The browser will then use that style sheet (or those style rules) when printing.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.