Click here to Skip to main content
15,888,221 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: How to play movie clips and swf files in asp.net Pin
Richard MacCutchan10-Feb-10 4:45
mveRichard MacCutchan10-Feb-10 4:45 
QuestionPopUp Pin
Civic0610-Feb-10 2:12
Civic0610-Feb-10 2:12 
AnswerRe: PopUp Pin
PunkIsNotDead10-Feb-10 8:32
PunkIsNotDead10-Feb-10 8:32 
GeneralRe: PopUp Pin
Civic0611-Feb-10 2:15
Civic0611-Feb-10 2:15 
QuestionBoundFiled/GridView Pin
-Muc_10-Feb-10 1:25
-Muc_10-Feb-10 1:25 
AnswerRe: BoundFiled/GridView Pin
PunkIsNotDead10-Feb-10 8:26
PunkIsNotDead10-Feb-10 8:26 
GeneralRe: BoundFiled/GridView Pin
-Muc_10-Feb-10 9:18
-Muc_10-Feb-10 9:18 
GeneralRe: BoundFiled/GridView Pin
PunkIsNotDead10-Feb-10 10:40
PunkIsNotDead10-Feb-10 10:40 
Using a css class
<style type="text/css" media="screen">
        .hiddencol /*Make invisible the column*/
        {
        	display:none;
        }
        
        .visiblecol /*Make visible the column*/
        {
        	display:block;
        }
    </style>

To hide / show the columns
<Columns>
                        <asp:CommandField HeaderText="Edit-Update" ShowEditButton="True" ItemStyle-CssClass="visiblecol"/>
<asp:ButtonField ButtonType="Link" CommandName="Save" ItemStyle-CssClass="hiddencol" />
                        <asp:BoundField DataField="SkillGroupID" Visible="false" ReadOnly="True" />

<asp:TemplateField>
<ItemTemplate>
<asp:Panel ID="Panel1" runat="server">
<asp:TextBox ID="Txt_Edit" Text='<%#Eval("SkillGroupName") %>' runat="server" Width="60px" ></asp:TextBox>
</asp:Panel>
<ItemStyle CssClass="hiddencol" />
</ItemTemplate>
</asp:TemplateField>

<asp:TemplateField>
<ItemTemplate>
<asp:Panel ID="Panel2" runat="server">
<asp:Label ID="Lbl_Edit" Text='<%#Eval("SkillGroupName") %>' runat="server" Width="60px" ></asp:Label>
</asp:Panel>
<ItemStyle CssClass="visiblecol" /&gt;
</ItemTemplate>
</asp:TemplateField>
                        
<asp:TemplateField>
<ItemTemplate>
<asp:ImageButton ID="ImageButton1" runat="Server" ImageUrl="~/Image/Hoch.JPG" CausesValidation="false" CommandName="Up" CommandArgument='<%# Container.DataItemIndex %>' Visible="True" />
<asp:ImageButton ID="ImageButton2" runat="Server" ImageUrl="~/Image/Runter.JPG" CausesValidation="false" CommandName="Down" CommandArgument='<%# Container.DataItemIndex %>' Visible="True" />;
</ItemTemplate>
</asp:TemplateField>
<asp:CommandField HeaderText="Delete" ShowDeleteButton="True" />
</Columns>

then in your RowCommand you can change the 'visiblecol' style by 'hiddencol' and 'hiddencol' by 'visiblecol' like I've posted before
QuestionIndex was outside the bounds of the array? Pin
mdrizwan_110-Feb-10 0:36
mdrizwan_110-Feb-10 0:36 
AnswerRe: Index was outside the bounds of the array? Pin
Gaurav Dudeja India10-Feb-10 1:13
Gaurav Dudeja India10-Feb-10 1:13 
GeneralRe: Index was outside the bounds of the array? Pin
mdrizwan_110-Feb-10 1:40
mdrizwan_110-Feb-10 1:40 
GeneralRe: Index was outside the bounds of the array? Pin
mdrizwan_110-Feb-10 1:47
mdrizwan_110-Feb-10 1:47 
GeneralRe: Index was outside the bounds of the array? Pin
Brij10-Feb-10 2:12
mentorBrij10-Feb-10 2:12 
AnswerRe: Index was outside the bounds of the array? Pin
Brij10-Feb-10 1:19
mentorBrij10-Feb-10 1:19 
GeneralRe: Index was outside the bounds of the array? Pin
mdrizwan_110-Feb-10 1:40
mdrizwan_110-Feb-10 1:40 
QuestionGoogle Map Pin
BK Komal10-Feb-10 0:25
BK Komal10-Feb-10 0:25 
AnswerRe: Google Map Pin
nainakarri10-Feb-10 1:03
nainakarri10-Feb-10 1:03 
GeneralRe: Google Map Pin
BK Komal10-Feb-10 1:07
BK Komal10-Feb-10 1:07 
GeneralRe: Google Map Pin
nainakarri10-Feb-10 1:18
nainakarri10-Feb-10 1:18 
GeneralRe: Google Map Pin
BK Komal10-Feb-10 2:12
BK Komal10-Feb-10 2:12 
Questionajax problem Pin
Mogamboo_Khush_Hua9-Feb-10 23:55
Mogamboo_Khush_Hua9-Feb-10 23:55 
AnswerRe: ajax problem Pin
Calla10-Feb-10 0:20
Calla10-Feb-10 0:20 
GeneralRe: ajax problem Pin
Mogamboo_Khush_Hua10-Feb-10 1:11
Mogamboo_Khush_Hua10-Feb-10 1:11 
QuestionNeed help in exporting Crystal report to stream Pin
Hema Bairavan9-Feb-10 22:27
Hema Bairavan9-Feb-10 22:27 
QuestionCurrently in register page and providing login details to login on keypress enter Pin
Nath9-Feb-10 22:20
Nath9-Feb-10 22:20 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.