Results 1 to 6 of 6

Thread: printing a web page

  1. #1

    Thread Starter
    Frenzied Member EyeTalion's Avatar
    Join Date
    Jul 2000
    Location
    New York
    Posts
    1,075

    printing a web page

    I want to place a button on my page so the user can print a datagrid. My first question is...

    1) Why doesn't the button move to the bottom of the datagrid? If there's to much data the button will overlap the datagrid, instead of moving to the bottom of the grid

    2)How can I just print the datagrid and not the rest of the page and can you have a print common dialog box pop up in asp.net so the user can choose printers?

    thanks,
    eye

  2. #2

    Thread Starter
    Frenzied Member EyeTalion's Avatar
    Join Date
    Jul 2000
    Location
    New York
    Posts
    1,075
    any printing advice out there?

  3. #3
    Lively Member
    Join Date
    Aug 2002
    Location
    outerspace
    Posts
    126
    if your using vs.net you may want to change grid layout to flow layout
    "All those who wonder are not lost" -j.r.r tolkien

  4. #4

    Thread Starter
    Frenzied Member EyeTalion's Avatar
    Join Date
    Jul 2000
    Location
    New York
    Posts
    1,075
    whats the difference?

  5. #5
    Lively Member
    Join Date
    Aug 2002
    Location
    outerspace
    Posts
    126
    Grid Layout absoultly positions your controls flow layout is more like a traditional web page where you have to use other devices to postions elements
    "All those who wonder are not lost" -j.r.r tolkien

  6. #6
    Hyperactive Member
    Join Date
    Dec 2001
    Location
    Dublin, Ireland
    Posts
    262
    For printing you can design your own custom printable version of your datagrid in a seperate web page or try crystal reports for asp.net.
    A custom method would not be that difficult but forget about paging it correctly unless you want to design intricate code that measures string sizes, widths heights, amount of lines that will ft on a page etc.
    I tend to say this over and over again but web pages are static html bar javascript and the idea of providing a print dialog etc. is nothing to do with asp.net. asp.net takes your code and returns html to the users browser via iis. Thats it, the magic is done and what the user sees is no different to what he/she might see on a normal html page. You could possibly embed control objects from windows apps but I'm not sure how this would work and you would have to rely on the user allowing the object to be download - all in all moving away from the purpose of asp.net in the first place, to provide a platform independent gui, i.e. the user needs nothing but a browser to use the application.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width