Unexpected datagrid behavior

Discussion in 'ASP .Net' started by G Dean Blake, Jan 13, 2005.

  1. G Dean Blake

    G Dean Blake Guest

    I am writing a control that prints any datagrid. My control gets passed a
    datagrid object and examines it, formats, and prints it. I am, however,
    encountering what I consider unexpected behavior of the grid....

    The grid is named dgBudgets.

    In the page Load event I fill the dataset and bind dgBudgets.
    I store dgBudgets in Session("myGrid").

    In response to the click event of the PrintMe button I pass
    Session("myGrid") to my control and call the print method. When doing this,
    every thing works great.

    But, if I pass dgBudgets to my control instead of Session("myGrid"),
    everything prints except that right aligned horizontal column alignments are
    notSet and non-visible columns are visible - everything else prints ok.

    So, it seems that on the response back, when the printMe button is hit,
    dgBudgets loses some of its attributes (although it is still visibly
    correct). My understanding is that the initializeComponent code on the
    response back should completely reconstruct the grid.

    Why does dgBudgets lose its alignment and non-visible settings and nothing
    else?

    Thanks,
    G
     
    G Dean Blake, Jan 13, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Chuck Bowling

    Unexpected page designer behavior

    Chuck Bowling, Jul 4, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    446
    Chuck Bowling
    Jul 4, 2005
  2. Victor Bazarov
    Replies:
    0
    Views:
    852
    Victor Bazarov
    Jun 25, 2003
  3. Russell Hanneken
    Replies:
    0
    Views:
    899
    Russell Hanneken
    Jun 25, 2003
  4. Juan Romero

    unexpected behavior in Datagrid paging : PLEASE HELP >: (

    Juan Romero, Sep 10, 2003, in forum: ASP .Net Datagrid Control
    Replies:
    1
    Views:
    127
    Alvin Bruney
    Sep 11, 2003
  5. G Dean Blake

    unexpected datagrid behavior

    G Dean Blake, Jan 13, 2005, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    113
    G Dean Blake
    Jan 13, 2005
Loading...

Share This Page