Image with text fields

4 posts, 0 answers
  1. Claude
    Claude avatar
    61 posts
    Member since:
    Apr 2009

    Posted 20 Jun 2010 Link to this post

    I have a background image that will be the same for all items, but I want 3 lines of text in front of the image that will vary for each item.  The text will be coing from a database.   

    I cannot figure out which type of item I should use and how to bind the 3 text fields.  I am using VB on this one. 

  2. Peter
    Admin
    Peter avatar
    1142 posts
    Member since:
    Sep 2012

    Posted 24 Jun 2010 Link to this post

    Hi Claude,

    Thanks for writing.

    After setting the background image, in order to put the text you can use RadLabel element (or RadButtonElement). Make sure that TextWrap property is set to true and set a MaxSize at your discretion in order to have the text on a few lines.

    Concerning the process of binding the text of the elements to a database, please take a look at this article. Basically, you should use the following approach:

    Sub radCarousel1_ItemDataBound(sender as object, e as ItemDataBoundEventArgs )
    Dim
    textFromDataBase as string = ....(extract text from e)
    me.radLabel1.Text = textFromDataBase
    me.radLabel1.Image = myImage
    me.radLabel1.TextImageRelation = TextImageRelation.Overlay

    For each item simply use the above approach to set the text. 

    I hope you find this information helpful. If you have any other questions, do not hesitate to contact us.

    Kind regards,
    Peter
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

  3. igumen
    igumen avatar
    2 posts
    Member since:
    Sep 2010

    Posted 29 Sep 2010 Link to this post

    Interesting code. Thanks.

    But my question is some Harder:
    Does anybody read or heard about any opportunities to make own "Elemets" for RadCarousel?  It is neccessary for my current work.

    Thx


  4. Vassil Petev
    Admin
    Vassil Petev avatar
    1766 posts
    Member since:
    Sep 2012

    Posted 29 Sep 2010 Link to this post

    Hi igumen,

    From the information provided, we are not sure what your requirements are. Please, review the Carousel Documentation and if you still have questions, please open a new support ticket and describe your requirements in detail so that we can assist you.


    Kind regards,
    Vassil
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Back to Top