datagrid issue
-
Hello, Thanks for reading this post. Here is my issue. I have a datagrid which 5 bound columns(3 of which are not visible) and 1 button column. Column 1 is date of operation, column 2 is text of email sent by my company etc. My issue is i want to display the entire content of the email text(which can be 2000 characters) inside the cell and have a scroll bar inside the cell, so the page does not become too big. For each row i would like to see the Date, The text of the email and if it exceeds the height of the row, then have a scroll bar within the email text column. How can I do that ?? All help is most appreciated !! This is what i have now.
-
Hello, Thanks for reading this post. Here is my issue. I have a datagrid which 5 bound columns(3 of which are not visible) and 1 button column. Column 1 is date of operation, column 2 is text of email sent by my company etc. My issue is i want to display the entire content of the email text(which can be 2000 characters) inside the cell and have a scroll bar inside the cell, so the page does not become too big. For each row i would like to see the Date, The text of the email and if it exceeds the height of the row, then have a scroll bar within the email text column. How can I do that ?? All help is most appreciated !! This is what i have now.
I think the best you can sensibly do is change the message_text column to a templatecolumn and place a readonly, multiline textbox in there and set it's value to the database field. You will get greyed out scrollbars if the text is short but that can't be helped. You can use css stylesheet to try and make the textbox blend in with the grid background as much as possible. (I'm not really sure sorting by message_text will produce anything sensible either - you'd be better off leaving that out. Not even sur you can if it corresponds to a text (as opposed to varchar) database field...)
-
I think the best you can sensibly do is change the message_text column to a templatecolumn and place a readonly, multiline textbox in there and set it's value to the database field. You will get greyed out scrollbars if the text is short but that can't be helped. You can use css stylesheet to try and make the textbox blend in with the grid background as much as possible. (I'm not really sure sorting by message_text will produce anything sensible either - you'd be better off leaving that out. Not even sur you can if it corresponds to a text (as opposed to varchar) database field...)
Thank you...I think that works fine. I created a template column and added a div with overflow property set to auto. That ensured whenever length or width went beyond, it would add scroll bars. works great. Thanks