Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 ASP.NET
 Increase the column size in a DataGrid

Author  Topic 

varunm
Starting Member

25 Posts

Posted - 2006-10-04 : 12:46:44
Hello ,
Please tell me how to increase the size of the particular column.


Help me ,its urgent.........

thanks

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-10-04 : 14:06:47
what size?
input text size? width, height?

You'll have to explain better.



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

varunm
Starting Member

25 Posts

Posted - 2006-10-04 : 14:13:17
its a input text, a column name Names: like
john
david
It should be john david in a column Names.

Increase the size of the column in a datagrid.
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-10-04 : 14:21:11
emm huh? i still have no idea what you want.

Are those 2 rows and you want to put them into one row?
is the column too narrow??

you can set the maximum number of chars to input with TextBox's MaxLength property.



Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

varunm
Starting Member

25 Posts

Posted - 2006-10-04 : 14:44:09
Okay,
I have a col1,col2 ,col3... in a datagrid.I just want to increase the size of col2.

*only col2 size,it mean in col2 we have name
john
David.
I want to make it as john david in a col2.I think u got an idea.


Thanks
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2006-10-04 : 14:49:18
yes but in col2 are jon and david
a) in one row of data but the text is wrapped
b) in 2 rows of data?

if a)
set the width property of the textbox to more than you have now.
http://www.syncfusion.com/faq/aspnet/search/288.aspx

if b)
you'll have to contencate them in the DB and return the list back




Go with the flow & have fun! Else fight the flow
blog thingie: http://weblogs.sqlteam.com/mladenp
Go to Top of Page

varunm
Starting Member

25 Posts

Posted - 2006-10-04 : 14:55:52
Yes,
I got u r answer.Its a)

here i changed the width of the col2, but it doestn't show up.I changed in the HTML-code.

i hope you can better assist me.

Thanks
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-10-04 : 19:15:53
varunm -- instead of playing a guessing game for 20 more posts, why don't you specifically tell us what you are doing .. using a bound column? templated column? Where does the textbox come from? It is generated by the datagrid, it is in a template, something you are adding programatically? How did you set the size of the column in "the HTML-code"? What does that mean? Can you give a brief but specific example? and so on.

My guess (and this is the only guess I am going to make, if you don't make it easy for us to help you then I'm not going to bother) is that you are using a bound column and asp.net is generating a textbox for the edit item that is too small. If that is the case, then use a templated column instead and in the "Edit Item Template" put in your own textbox and set the width of the textbox to be the size you want.

If that doesn't help you, put some effort into your question and please be specific and give us a clear picture of your situation so that we can help you.

- Jeff
Go to Top of Page

varunm
Starting Member

25 Posts

Posted - 2006-10-04 : 22:44:22
Thanks for All,
My problem is soved.
Go to Top of Page

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-10-05 : 07:09:37
How did you solve it?

- Jeff
Go to Top of Page
   

- Advertisement -