Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 2.0 > ASP.NET 2.0 Professional
Password Reminder
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 24th, 2006, 04:05 AM
Registered User
Join Date: May 2006
Location: Copenhagen, , Denmark.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default DataGrid renders different on different machines


I'm working on a .NET application and has run into an annoying problem.

I have a report, that consists of a DataGrid, wher I have disabled the AutoGenerateColumns, as I'm binding the columns myself.

I have turned on nowrap on "Header" and "Item", and is explicit setting width (bcol.ItemStyle.Width = Unit.Pixel(270); )

the problem is, that on my own machine and the "production"-server, the HTML renders differently, so the "<table>" does not respect the width I have set.

This is the data for the 2 machines:

XP Professional version 2002 sp2
MSIE 6.0.2900.2180.xpsp_sp2_gdr.050301-1519
ASP .Net (v2.0.50727).

the other:
XP Professional version 2002 sp2
MSIE 6.0.2900.2180.xpsp_sp2_gdr.050301-1519
ASP .Net (v2.0.50727).

regardless of the "identicality" of the two machines, the resulting HTML is as follows:

my machine:
   <td nowrap="nowrap" align="left" style="font-weight:bold;width:270px;"></td>

and the other:
   <td align="left" style="font-weight:bold;width:270px;white-space:nowrap;"></td>

Note, that the "nowrap" is different. As far as I can tell, the style-attribute on the "other" machine is invalidating the <td>-tag, and thus the table does not respect the "width"-setting.

Can anyone explain why this is? Where is the difference between the two machines? And even better - how can I get the other machine to render the HTML like my own machine?

Thanks in advance

  #2 (permalink)  
Old May 25th, 2006, 10:21 PM
Friend of Wrox
Points: 4,332, Level: 27
Points: 4,332, Level: 27 Points: 4,332, Level: 27 Points: 4,332, Level: 27
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Nov 2003
Location: , NJ, USA.
Posts: 1,348
Thanks: 0
Thanked 5 Times in 5 Posts

cross post:


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Working with the book on two machines... Bruce.Wiki BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 5 October 30th, 2008 11:53 AM
Insert renders error snufse SQL Language 2 October 13th, 2008 09:28 PM
DataGrid renders different on different machines GertFrost ASP.NET 2.0 Basics 1 June 19th, 2007 03:34 PM
dw renders my css when previewed in browser? jakewilliamson Dreamweaver (all versions) 5 March 21st, 2005 05:42 AM

All times are GMT -4. The time now is 08:30 AM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.