Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. How should I do this? Need advice.

How should I do this? Need advice.

Scheduled Pinned Locked Moved ASP.NET
dockerhelpquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shapper
    wrote on last edited by
    #1

    Hello, I have a problem: Inside the Item Template of an ASP:Repeater I need to display a link. The link url value is given by: <%# DataBinder.Eval(Container.DataItem, "link") %> The link text changes according to the culture of my web site: "pt-PT" - Lêr Mais "en-GB" - Read More ... I tried to use a tag where the text is taken from a public variable. OR To use an ASP: Hiperlink. Anyway, I am having problems in both and I am not even sure if there are the best options I also have a session variable, session("culture"), where current culture is available. Can someone advice me on this? I know this is simple but I am having problems with it. Thank You, Miguel

    C A 2 Replies Last reply
    0
    • S shapper

      Hello, I have a problem: Inside the Item Template of an ASP:Repeater I need to display a link. The link url value is given by: <%# DataBinder.Eval(Container.DataItem, "link") %> The link text changes according to the culture of my web site: "pt-PT" - Lêr Mais "en-GB" - Read More ... I tried to use a tag where the text is taken from a public variable. OR To use an ASP: Hiperlink. Anyway, I am having problems in both and I am not even sure if there are the best options I also have a session variable, session("culture"), where current culture is available. Can someone advice me on this? I know this is simple but I am having problems with it. Thank You, Miguel

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Use an ASP Hyperlink for sure, or you lose a lot of the advantages of ASP.NET. Then set the text as a property, like I showed you for something else earlier today. Although I still don't think the session variable used in code all over the place is the right way to go. Christian Graus - Microsoft MVP - C++

      1 Reply Last reply
      0
      • S shapper

        Hello, I have a problem: Inside the Item Template of an ASP:Repeater I need to display a link. The link url value is given by: <%# DataBinder.Eval(Container.DataItem, "link") %> The link text changes according to the culture of my web site: "pt-PT" - Lêr Mais "en-GB" - Read More ... I tried to use a tag where the text is taken from a public variable. OR To use an ASP: Hiperlink. Anyway, I am having problems in both and I am not even sure if there are the best options I also have a session variable, session("culture"), where current culture is available. Can someone advice me on this? I know this is simple but I am having problems with it. Thank You, Miguel

        A Offline
        A Offline
        atul_moghe
        wrote on last edited by
        #3

        hi Miguel, i think u can bind ur data or link in itemdatabound event and in tht u can get the culture bye 'CultureInfo.CurrentCulture.Name'. I think its good solution if i got ur problem in proper manner. bye n take care, A R MOGHE.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups