Professional Web Applications Themes

changing the template column's position ? - ASP.NET Data Grid Control

Hi all, By default when we create a Template Column, the position of the Template Column will be 1. Is it possible to change its position at Design Time or Runtime i.e if I want a Template Column to be at no. 2, then how can we do this? Thanks, Gary...

  1. #1

    Default changing the template column's position ?

    Hi all,

    By default when we create a Template Column, the position of the Template
    Column

    will be 1. Is it possible to change its position at Design Time or Runtime
    i.e if I want a Template Column to be at no. 2,

    then how can we do this?

    Thanks,

    Gary


    Gary Guest

  2. #2

    Default RE: changing the template column's position ?

    Hi Gary,

    1) If you use Property Builder
    Select the column to be moved and click on the up & down arrows to move it.

    2) Without Property Builder
    Switch to HTML View and you will see something like this:
    <Columns>
    <asp:TemplateColumn HeaderText="One"></asp:TemplateColumn>
    <asp:TemplateColumn HeaderText="Two"></asp:TemplateColumn>
    </Columns>

    Edit this text to place column two above column one.

    Does this answer your question?

    Thank you, Mike
    Microsoft, ASP.NET Support Professional

    Microsoft highly recommends to all of our customers that they visit the
    [url]http://www.microsoft.com/protect[/url] site and perform the three straightforward
    steps listed to improve your computerís security.

    This posting is provided "AS IS", with no warranties, and confers no rights.


    --------------------
    > From: "Gary" <msnewsmicrosoft.com>
    > Subject: changing the template column's position ?
    > Date: Tue, 14 Oct 2003 17:53:09 +0530
    > Lines: 15
    > X-Priority: 3
    > X-MSMail-Priority: Normal
    > X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
    > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
    > Message-ID: <#7mMx3kkDHA.2080TK2MSFTNGP10.phx.gbl>
    > Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > NNTP-Posting-Host: 61.11.24.47
    > Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTN GP10.phx.gbl
    > Xref: cpmsftngxa06.phx.gbl
    microsoft.public.dotnet.framework.aspnet.datagridc ontrol:7039
    > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    >
    > Hi all,
    >
    > By default when we create a Template Column, the position of the Template
    > Column
    >
    > will be 1. Is it possible to change its position at Design Time or
    Runtime
    > i.e if I want a Template Column to be at no. 2,
    >
    > then how can we do this?
    >
    > Thanks,
    >
    > Gary
    >
    >
    >
    Mike Moore [MSFT] Guest

  3. #3

    Default Re: changing the template column's position ?

    Yes, thanks a lot.

    - Gary -

    ""Mike Moore [MSFT]"" <michmoonline.microsoft.com> wrote in message
    news:YfaBFApkDHA.1716cpmsftngxa06.phx.gbl...
    > Hi Gary,
    >
    > 1) If you use Property Builder
    > Select the column to be moved and click on the up & down arrows to move
    it.
    >
    > 2) Without Property Builder
    > Switch to HTML View and you will see something like this:
    > <Columns>
    > <asp:TemplateColumn HeaderText="One"></asp:TemplateColumn>
    > <asp:TemplateColumn HeaderText="Two"></asp:TemplateColumn>
    > </Columns>
    >
    > Edit this text to place column two above column one.
    >
    > Does this answer your question?
    >
    > Thank you, Mike
    > Microsoft, ASP.NET Support Professional
    >
    > Microsoft highly recommends to all of our customers that they visit the
    > [url]http://www.microsoft.com/protect[/url] site and perform the three
    straightforward
    > steps listed to improve your computer's security.
    >
    > This posting is provided "AS IS", with no warranties, and confers no
    rights.
    >
    >
    > --------------------
    > > From: "Gary" <msnewsmicrosoft.com>
    > > Subject: changing the template column's position ?
    > > Date: Tue, 14 Oct 2003 17:53:09 +0530
    > > Lines: 15
    > > X-Priority: 3
    > > X-MSMail-Priority: Normal
    > > X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
    > > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
    > > Message-ID: <#7mMx3kkDHA.2080TK2MSFTNGP10.phx.gbl>
    > > Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > > NNTP-Posting-Host: 61.11.24.47
    > > Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTN GP10.phx.gbl
    > > Xref: cpmsftngxa06.phx.gbl
    > microsoft.public.dotnet.framework.aspnet.datagridc ontrol:7039
    > > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > >
    > > Hi all,
    > >
    > > By default when we create a Template Column, the position of the
    Template
    > > Column
    > >
    > > will be 1. Is it possible to change its position at Design Time or
    > Runtime
    > > i.e if I want a Template Column to be at no. 2,
    > >
    > > then how can we do this?
    > >
    > > Thanks,
    > >
    > > Gary
    > >
    > >
    > >
    >

    Gary Guest

  4. #4

    Default Re: changing the template column's position ?

    But the only thing is
    that I have only 1 Template column and i am binding my Datagrid with a
    dataset, I

    am creating a template column to put Text box so the user can enter Qty, but
    by

    default the Template Column comes to the 1st position, actually i want the
    template

    column to be at no.2 or at the end of the grid.

    Please suggest.

    Thanks again,

    Gary


    "Gary" <msnewsmicrosoft.com> wrote in message
    news:uKiPgDtkDHA.424TK2MSFTNGP10.phx.gbl...
    > Yes, thanks a lot.
    >
    > - Gary -
    >
    > ""Mike Moore [MSFT]"" <michmoonline.microsoft.com> wrote in message
    > news:YfaBFApkDHA.1716cpmsftngxa06.phx.gbl...
    > > Hi Gary,
    > >
    > > 1) If you use Property Builder
    > > Select the column to be moved and click on the up & down arrows to move
    > it.
    > >
    > > 2) Without Property Builder
    > > Switch to HTML View and you will see something like this:
    > > <Columns>
    > > <asp:TemplateColumn HeaderText="One"></asp:TemplateColumn>
    > > <asp:TemplateColumn HeaderText="Two"></asp:TemplateColumn>
    > > </Columns>
    > >
    > > Edit this text to place column two above column one.
    > >
    > > Does this answer your question?
    > >
    > > Thank you, Mike
    > > Microsoft, ASP.NET Support Professional
    > >
    > > Microsoft highly recommends to all of our customers that they visit the
    > > [url]http://www.microsoft.com/protect[/url] site and perform the three
    > straightforward
    > > steps listed to improve your computer's security.
    > >
    > > This posting is provided "AS IS", with no warranties, and confers no
    > rights.
    > >
    > >
    > > --------------------
    > > > From: "Gary" <msnewsmicrosoft.com>
    > > > Subject: changing the template column's position ?
    > > > Date: Tue, 14 Oct 2003 17:53:09 +0530
    > > > Lines: 15
    > > > X-Priority: 3
    > > > X-MSMail-Priority: Normal
    > > > X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
    > > > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
    > > > Message-ID: <#7mMx3kkDHA.2080TK2MSFTNGP10.phx.gbl>
    > > > Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > > > NNTP-Posting-Host: 61.11.24.47
    > > > Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTN GP10.phx.gbl
    > > > Xref: cpmsftngxa06.phx.gbl
    > > microsoft.public.dotnet.framework.aspnet.datagridc ontrol:7039
    > > > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > > >
    > > > Hi all,
    > > >
    > > > By default when we create a Template Column, the position of the
    > Template
    > > > Column
    > > >
    > > > will be 1. Is it possible to change its position at Design Time or
    > > Runtime
    > > > i.e if I want a Template Column to be at no. 2,
    > > >
    > > > then how can we do this?
    > > >
    > > > Thanks,
    > > >
    > > > Gary
    > > >
    > > >
    > > >
    > >
    >
    >

    Gary Guest

  5. #5

    Default Re: changing the template column's position ?

    Hi Gary,

    Let me see if I have this correct. You have auto-generate-columns set to
    true and you want a template column to display after the auto column(s). I
    hope I understand this correctly.

    Unfortunately, the auto columns always add to the right. You can re-arrange
    this by adding your columns in advance rather than using auto generate.

    Does this answer your question?

    Thank you, Mike
    Microsoft, ASP.NET Support Professional

    Microsoft highly recommends to all of our customers that they visit the
    [url]http://www.microsoft.com/protect[/url] site and perform the three straightforward
    steps listed to improve your computerís security.

    This posting is provided "AS IS", with no warranties, and confers no rights.


    --------------------
    > From: "Gary" <msnewsmicrosoft.com>
    > References: <#7mMx3kkDHA.2080TK2MSFTNGP10.phx.gbl>
    <YfaBFApkDHA.1716cpmsftngxa06.phx.gbl>
    <uKiPgDtkDHA.424TK2MSFTNGP10.phx.gbl>
    > Subject: Re: changing the template column's position ?
    > Date: Wed, 15 Oct 2003 13:11:07 +0530
    > Lines: 96
    > X-Priority: 3
    > X-MSMail-Priority: Normal
    > X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
    > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
    > Message-ID: <#aVwz#ukDHA.2160TK2MSFTNGP10.phx.gbl>
    > Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > NNTP-Posting-Host: 61.11.24.47
    > Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTN GP10.phx.gbl
    > Xref: cpmsftngxa06.phx.gbl
    microsoft.public.dotnet.framework.aspnet.datagridc ontrol:7055
    > X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    >
    > But the only thing is
    > that I have only 1 Template column and i am binding my Datagrid with a
    > dataset, I
    >
    > am creating a template column to put Text box so the user can enter Qty,
    but
    > by
    >
    > default the Template Column comes to the 1st position, actually i want the
    > template
    >
    > column to be at no.2 or at the end of the grid.
    >
    > Please suggest.
    >
    > Thanks again,
    >
    > Gary
    >
    >
    > "Gary" <msnewsmicrosoft.com> wrote in message
    > news:uKiPgDtkDHA.424TK2MSFTNGP10.phx.gbl...
    > > Yes, thanks a lot.
    > >
    > > - Gary -
    > >
    > > ""Mike Moore [MSFT]"" <michmoonline.microsoft.com> wrote in message
    > > news:YfaBFApkDHA.1716cpmsftngxa06.phx.gbl...
    > > > Hi Gary,
    > > >
    > > > 1) If you use Property Builder
    > > > Select the column to be moved and click on the up & down arrows to
    move
    > > it.
    > > >
    > > > 2) Without Property Builder
    > > > Switch to HTML View and you will see something like this:
    > > > <Columns>
    > > > <asp:TemplateColumn HeaderText="One"></asp:TemplateColumn>
    > > > <asp:TemplateColumn HeaderText="Two"></asp:TemplateColumn>
    > > > </Columns>
    > > >
    > > > Edit this text to place column two above column one.
    > > >
    > > > Does this answer your question?
    > > >
    > > > Thank you, Mike
    > > > Microsoft, ASP.NET Support Professional
    > > >
    > > > Microsoft highly recommends to all of our customers that they visit
    the
    > > > [url]http://www.microsoft.com/protect[/url] site and perform the three
    > > straightforward
    > > > steps listed to improve your computer's security.
    > > >
    > > > This posting is provided "AS IS", with no warranties, and confers no
    > > rights.
    > > >
    > > >
    > > > --------------------
    > > > > From: "Gary" <msnewsmicrosoft.com>
    > > > > Subject: changing the template column's position ?
    > > > > Date: Tue, 14 Oct 2003 17:53:09 +0530
    > > > > Lines: 15
    > > > > X-Priority: 3
    > > > > X-MSMail-Priority: Normal
    > > > > X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
    > > > > X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
    > > > > Message-ID: <#7mMx3kkDHA.2080TK2MSFTNGP10.phx.gbl>
    > > > > Newsgroups: microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > > > > NNTP-Posting-Host: 61.11.24.47
    > > > > Path: cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTN GP10.phx.gbl
    > > > > Xref: cpmsftngxa06.phx.gbl
    > > > microsoft.public.dotnet.framework.aspnet.datagridc ontrol:7039
    > > > > X-Tomcat-NG:
    microsoft.public.dotnet.framework.aspnet.datagridc ontrol
    > > > >
    > > > > Hi all,
    > > > >
    > > > > By default when we create a Template Column, the position of the
    > > Template
    > > > > Column
    > > > >
    > > > > will be 1. Is it possible to change its position at Design Time or
    > > > Runtime
    > > > > i.e if I want a Template Column to be at no. 2,
    > > > >
    > > > > then how can we do this?
    > > > >
    > > > > Thanks,
    > > > >
    > > > > Gary
    > > > >
    > > > >
    > > > >
    > > >
    > >
    > >
    >
    >
    >
    Mike Moore [MSFT] Guest

Similar Threads

  1. Template column base on another column value
    By Esperanza in forum ASP.NET Data Grid Control
    Replies: 5
    Last Post: February 21st, 04:02 PM
  2. Replies: 2
    Last Post: April 29th, 05:16 PM
  3. Bound Column or Template Column (w dAdapater?) in DataGrid
    By Ravichandran Mahalingam in forum ASP.NET Data Grid Control
    Replies: 0
    Last Post: January 9th, 03:30 PM
  4. Changing the binding of a template column
    By Rob Edwards in forum ASP.NET Data Grid Control
    Replies: 2
    Last Post: October 17th, 02:06 PM
  5. changing the position in a table
    By Andi Fenner in forum Macromedia Dreamweaver
    Replies: 0
    Last Post: July 21st, 08:28 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139