473,406 Members | 2,549 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

GridView and master

Hi All,

Is there any way to write a CSS kinda header or table definition in
Master Page, so that all GridViews in child pages have the same looks?

Regards,
Prakash.

Aug 7 '06 #1
3 1098
"Hari" <ha*****@gmail.comwrote in message
news:11**********************@i42g2000cwa.googlegr oups.com...
Is there any way to write a CSS kinda header or table definition in
Master Page, so that all GridViews in child pages have the same looks?
1) Create a stylesheet
2) Add the various styles you want for your GridViews
3) Add a reference to the stylesheet in the header section of your
MasterPage

What problem are you having...?
Aug 7 '06 #2
You should use CSS classes for this. GridViews are ASP.net controls that
render out whatever HTML is aplicable to the relevent browser. You cannot
set a style in a style sheet that will apply to all GridViews the same say
you can for HTML elements such as <table<bodyetc. GridViews have a
CSSClass property. Set up a css class in your style sheet then set the
cssclass property of the GridView to refer to it.

"Hari" wrote:
Hi All,

Is there any way to write a CSS kinda header or table definition in
Master Page, so that all GridViews in child pages have the same looks?

Regards,
Prakash.

Aug 7 '06 #3
Hi Rae, Clickon,

I know this usual way. I do like this in HTML. I'm a PHP programmer
and at last turned to ASP.NET. I just started learning. I thought it
would be nice, If I visually design sample table and its styles in
Master Page and I just make style reference in the child pages.

Suppose I have GridView in Two Pages, like Default format is
separately available in that controls. If have a sample GridView in
master page, and it has a style which reflects in all gridviews using
that master page. Anyway your solution works fine.

Thank you.

Regards,
Hari.

Aug 7 '06 #4

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

Similar topics

0
by: hazz | last post by:
A treeview control should be able to select various aspx pages in the site. (using sitemap) One content page will have a gridview, accessed through a content place holder while another aspx page...
0
by: John Smith | last post by:
ASP.Net 2.0 / C# / IIS 6 I have 2 pages. The master page consists of a tabbed menu created using the Menu and MultiView controls. Something like this: ...
0
by: ThePurpleCat | last post by:
Hi, I'm a newbie to ASP.NET programming but not to Visual Studio. I'm having trouble getting my Master-Details page to work. I have a page enabled GridView which is linked to a FormView control...
4
by: =?Utf-8?B?QW1pciBUb2hpZGk=?= | last post by:
Hi I have a GridView that is displaying master records. Some of these records have child records. I would like to a column to my master GridView such that for each master record that has...
1
by: Yordan Georgiev | last post by:
I have a search form using master page , which is dynamically generated from the column names of the database - when the users have a search result it should be exported to Excel by clicking the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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
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,...
0
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...

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.