Column span all columns when Gridview Data is empty

Hello Experts,

I was trying to show gridview Headers , when there is no data, but I cannot column span all columns and remove the rowstyle and show the text "No Data Present".

Sample gridview:

ID         NAME
--        ------------

     NO DATA PRESENT


Something like above.
ASPDEVAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
guru_samiConnect With a Mentor Commented:
Then there isn't an built-in way but weird workarounds.
Some of them listed here
0
 
guru_samiCommented:
With 4.0 you can set ShowHeaderWhenEmpty="True" and have EmptyDataTemplate to have your text.
0
 
ASPDEVAuthor Commented:
Sorry, It was ASP.NET 3.5.
0
 
ASPDEVAuthor Commented:
Thanks.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.