473,499 Members | 1,873 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

datagrid edit textboxes

Hey all,

I have a datagrid on an asp.net page and I'm using the in-line editing
feature where you can edit a value right on the datagrid. I was wondering if
I can make the textboxes a smaller width. If so, how please?

thanks,
rodchar
Nov 18 '05 #1
2 1207
One way is to specify the controls for the edit mode using a template, and
then set the width of the Texbox - for example:
<EditItemTemplate>
....
<ASP:TextBox id="txtTitle" Text='<%# Container.DataItem("Title") %>'
size="46" runat="server" /><br />
....
</EditItemTemplate>

this code is form this example:
http://www.daveandal.net/books/8900/...-datalist.aspx
which has a [view source] link.
"rodchar" <ro*****@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
Hey all,

I have a datagrid on an asp.net page and I'm using the in-line editing
feature where you can edit a value right on the datagrid. I was wondering if I can make the textboxes a smaller width. If so, how please?

thanks,
rodchar

Nov 18 '05 #2
thank you.

"Alex Homer" wrote:
One way is to specify the controls for the edit mode using a template, and
then set the width of the Texbox - for example:
<EditItemTemplate>
....
<ASP:TextBox id="txtTitle" Text='<%# Container.DataItem("Title") %>'
size="46" runat="server" /><br />
....
</EditItemTemplate>

this code is form this example:
http://www.daveandal.net/books/8900/...-datalist.aspx
which has a [view source] link.
"rodchar" <ro*****@discussions.microsoft.com> wrote in message
news:5E**********************************@microsof t.com...
Hey all,

I have a datagrid on an asp.net page and I'm using the in-line editing
feature where you can edit a value right on the datagrid. I was wondering

if
I can make the textboxes a smaller width. If so, how please?

thanks,
rodchar


Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
2312
by: Gilles T. | last post by:
How I can get element ID in the edit mode of datagrid control? If I not in the edit mode, there are no problem. <asp:TemplateColumn ItemStyle-CssClass="grid_column_width_3"...
1
1332
by: Pavel Gusak | last post by:
Hello. I've found DataGrid built-in edit functionality useless. My DataGrid has 9 columns, and is shown just nice until I press 'Edit' on a row. ASP.NET creates 9 TextBoxes, all the same very big...
1
1198
by: Demetri | last post by:
I have a datagrid on an aspx page with one column added via property builder - the edit/update/cancel. In addition there is a dropdownlist which has a list of table names. Upon selecting one of...
2
5906
by: Fluxray | last post by:
--Background: I have a webform including a datagrid. The datagrid is using template. Its ItemTemplate is used to display a look-up-table with labels. its EditItemTemplate is used to edit a row in...
3
1617
by: Leo | last post by:
I have a datagrid with the first column as a Edit,Update,Cancel button column. The other 5 columns are template columns. When I click the Edit button in IE6 the row correctly displays the...
2
1327
by: Shankar Mani via DotNetMonster.com | last post by:
Hi folks, I am facing a problem while using a DataGrid. I have a webform with a datagrid containing two text boxes for edit viz., countrycode and country name. Like wise I have two more text boxes...
1
1322
by: David Sagenaut | last post by:
Can I set a whole datagrid in edit mode, like a table? I can edit the data in the datagrid. After done, I can click the save button to save the data into a datasousce. I don't want to used the...
0
1739
by: Erik | last post by:
Why isn't my update method getting called? Pasted below is an aspx from a 1.1 application I'm working on. It has two textboxes and a button for inserting data into the database, and a datagrid...
9
2706
by: rn5a | last post by:
A Form has a DataGrid which displays records from a SQL Server 2005 DB table. Users can modify the records using this DataGrid for which I am using EditCommandColumn in the DataGrid. This is the...
6
3336
by: rn5a | last post by:
When the EditCommandColumn in a DataGrid is clicked, all the BoundColumns get replaced by TextBoxes so that users can alter the data. By default, the Text in the TextBoxes are left-aligned. Is...
0
7134
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7180
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6901
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7392
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5479
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4920
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3105
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1429
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
667
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.