Repeater/No Data message -- How?

Discussion in 'ASP .Net' started by Chad A. Beckner, Jun 16, 2004.

  1. Hey all,

    I have a repeater setup which pulls data from a SQL server. If there is
    no data, I want to display a message "No Data". How can I do this?

    Thanks in advance!

    Chad
    Chad A. Beckner, Jun 16, 2004
    #1
    1. Advertising

  2. Chad A. Beckner

    Cliff Harris Guest

    I usually just have a label right above my repeater that I default to not
    visible. Then, when I fill up the datatable that I am going to bind to the
    repeater. I check the row count. If it's 0, I hide the repeater and show
    the label that says there is no data.

    HTH,
    -Cliff

    "Chad A. Beckner" <> wrote in message
    news:%...
    > Hey all,
    >
    > I have a repeater setup which pulls data from a SQL server. If there is
    > no data, I want to display a message "No Data". How can I do this?
    >
    > Thanks in advance!
    >
    > Chad
    >
    >
    Cliff Harris, Jun 16, 2004
    #2
    1. Advertising

  3. I figured as much, that's what I just got done doing. So, you "can" or "can
    not" add the label dynamically (at runtime) and then hide the repeater (in
    essence, replacing it?)

    Chad

    "Cliff Harris" <> wrote in message
    news:%...
    > I usually just have a label right above my repeater that I default to not
    > visible. Then, when I fill up the datatable that I am going to bind to

    the
    > repeater. I check the row count. If it's 0, I hide the repeater and show
    > the label that says there is no data.
    >
    > HTH,
    > -Cliff
    >
    > "Chad A. Beckner" <> wrote in message
    > news:%...
    > > Hey all,
    > >
    > > I have a repeater setup which pulls data from a SQL server. If there

    is
    > > no data, I want to display a message "No Data". How can I do this?
    > >
    > > Thanks in advance!
    > >
    > > Chad
    > >
    > >

    >
    >
    Chad A. Beckner, Jun 16, 2004
    #3
  4. Chad A. Beckner

    Cliff Harris Guest

    I guess you could add the label dynamically... it's just a lot easier if I
    don't have to worry about adding it to the page in the right place, etc. So
    I just hide it. Hack? I don't think so, but, hey, that's me.

    -Cliff

    "Chad A. Beckner" <> wrote in message
    news:OprK%...
    > I figured as much, that's what I just got done doing. So, you "can" or

    "can
    > not" add the label dynamically (at runtime) and then hide the repeater (in
    > essence, replacing it?)
    >
    > Chad
    >
    > "Cliff Harris" <> wrote in message
    > news:%...
    > > I usually just have a label right above my repeater that I default to

    not
    > > visible. Then, when I fill up the datatable that I am going to bind to

    > the
    > > repeater. I check the row count. If it's 0, I hide the repeater and

    show
    > > the label that says there is no data.
    > >
    > > HTH,
    > > -Cliff
    > >
    > > "Chad A. Beckner" <> wrote in message
    > > news:%...
    > > > Hey all,
    > > >
    > > > I have a repeater setup which pulls data from a SQL server. If

    there
    > is
    > > > no data, I want to display a message "No Data". How can I do this?
    > > >
    > > > Thanks in advance!
    > > >
    > > > Chad
    > > >
    > > >

    > >
    > >

    >
    >
    Cliff Harris, Jun 17, 2004
    #4
  5. Chad A. Beckner

    zkamal

    Joined:
    Aug 10, 2011
    Messages:
    1
    zkamal, Aug 10, 2011
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    841
  2. Replies:
    0
    Views:
    2,862
  3. Replies:
    1
    Views:
    7,007
    Karl Seguin
    Aug 10, 2005
  4. uncensored
    Replies:
    0
    Views:
    793
    uncensored
    Oct 25, 2006
  5. Microsoft

    Repeater inside a Repeater

    Microsoft, Aug 21, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    191
    Microsoft
    Aug 21, 2006
Loading...

Share This Page