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. how to printout data stored in server-side?

how to printout data stored in server-side?

Scheduled Pinned Locked Moved ASP.NET
databasesysadmintutorialquestion
6 Posts 3 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.
  • M Offline
    M Offline
    mijan
    wrote on last edited by
    #1

    Any idea on how we can code for printing out the data which resides in server-side?let say we have name, date and ID number in the database.so we to print these out on a sticker.(hardopy) mijan

    P 1 Reply Last reply
    0
    • M mijan

      Any idea on how we can code for printing out the data which resides in server-side?let say we have name, date and ID number in the database.so we to print these out on a sticker.(hardopy) mijan

      P Offline
      P Offline
      Plunging_Falcon
      wrote on last edited by
      #2

      What exactly is the problem? Is it the printing or the displaying? If you want to display the data on the screen just use a DataGrid and populate it using a DataReader and then you print it if you wish.

      M 1 Reply Last reply
      0
      • P Plunging_Falcon

        What exactly is the problem? Is it the printing or the displaying? If you want to display the data on the screen just use a DataGrid and populate it using a DataReader and then you print it if you wish.

        M Offline
        M Offline
        mijan
        wrote on last edited by
        #3

        it is actually for printing purpose. if i use datagrid to display and then the next thing is to print this stuff.So is it gonna use JavaScript as well? specifically how am I to print the datagrid? mijan

        P 1 Reply Last reply
        0
        • M mijan

          it is actually for printing purpose. if i use datagrid to display and then the next thing is to print this stuff.So is it gonna use JavaScript as well? specifically how am I to print the datagrid? mijan

          P Offline
          P Offline
          Plunging_Falcon
          wrote on last edited by
          #4

          I think you can do it using "execCommand" with JavaScript. it should be something along the lines of 'execCommand("Print")', check the syntax in msdn. That means you need a page with the datagrid on it (you can remove all custom design for a printer friendly version) and then activate the command.

          G 1 Reply Last reply
          0
          • P Plunging_Falcon

            I think you can do it using "execCommand" with JavaScript. it should be something along the lines of 'execCommand("Print")', check the syntax in msdn. That means you need a page with the datagrid on it (you can remove all custom design for a printer friendly version) and then activate the command.

            G Offline
            G Offline
            gnjunge
            wrote on last edited by
            #5

            self.print() window.print() are the javascript commands to print (works in any browser).

            M 1 Reply Last reply
            0
            • G gnjunge

              self.print() window.print() are the javascript commands to print (works in any browser).

              M Offline
              M Offline
              mijan
              wrote on last edited by
              #6

              thanks guys! i really gonna put a hand on it..=) mijan

              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