Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Printing Datagrids in ASP.net

Printing Datagrids in ASP.net

Scheduled Pinned Locked Moved ASP.NET
csharpasp-nethelptutorial
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    umashankergr8
    wrote on last edited by
    #1

    Hi All, I have some ASP.Net web pages that use C# as code behind. On those ASPX pages, there r some datagrids that I want to print. I have seen help about printing datagrids on standalone applications but dont know how to do it on WebBased applications such as mine. Any help/ideas/urls wud be greatly appreciated Thanx Umashanker.k

    S 1 Reply Last reply
    0
    • U umashankergr8

      Hi All, I have some ASP.Net web pages that use C# as code behind. On those ASPX pages, there r some datagrids that I want to print. I have seen help about printing datagrids on standalone applications but dont know how to do it on WebBased applications such as mine. Any help/ideas/urls wud be greatly appreciated Thanx Umashanker.k

      S Offline
      S Offline
      Suresh Pirsquare
      wrote on last edited by
      #2

      Try the below mentioned code:- function CallPrint(strid) { var prtContent = document.getElementById(strid); var WinPrint = window.open('','','letf=0,top=0,width=1,height=1,toolbar=0,scrollbars=0,status=0'); WinPrint.document.write(prtContent.innerHTML); WinPrint.document.close(); WinPrint.focus(); WinPrint.print(); WinPrint.close(); prtContent.innerHTML=strOldOne; }

      ..... ..... .....

      :)

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups