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
  1. Home
  2. Web Development
  3. ASP.NET
  4. Looking for the appropriate control

Looking for the appropriate control

Scheduled Pinned Locked Moved ASP.NET
questioncsharphtmlcom
5 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.
  • M Offline
    M Offline
    Matt Newman
    wrote on last edited by
    #1

    I have a web user control (in C#) that generates a series of html tables etc in the code behind file. How do I set the display (i.e. the ascx file) render with the html I have created. I tried creating a ASP label but I ran into some big sizing issues. Is there a better way to do this? Matt Newman
    All rise for the honorable Judge Stone Cold Steve Austin - From Dilbert Episode 30

    M P 2 Replies Last reply
    0
    • M Matt Newman

      I have a web user control (in C#) that generates a series of html tables etc in the code behind file. How do I set the display (i.e. the ascx file) render with the html I have created. I tried creating a ASP label but I ran into some big sizing issues. Is there a better way to do this? Matt Newman
      All rise for the honorable Judge Stone Cold Steve Austin - From Dilbert Episode 30

      M Offline
      M Offline
      Marcie Jones
      wrote on last edited by
      #2

      A Literal might be better than a Label, since I believe Label's put everything inside of a [span]. Marcie CP Blog[^]

      M 1 Reply Last reply
      0
      • M Matt Newman

        I have a web user control (in C#) that generates a series of html tables etc in the code behind file. How do I set the display (i.e. the ascx file) render with the html I have created. I tried creating a ASP label but I ran into some big sizing issues. Is there a better way to do this? Matt Newman
        All rise for the honorable Judge Stone Cold Steve Austin - From Dilbert Episode 30

        P Offline
        P Offline
        Paul Watson
        wrote on last edited by
        #3

        I may have your situation wrong but the best way would be to override the OnRender event of the ASCX and spit it out to the provided HtmlWriter. Or a literal as Marcie suggests. What sizing issues are you having? regards, Paul Watson Bluegrass South Africa Chris Maunder wrote: "I'd rather cover myself in honey and lie on an ant's nest than commit myself to it publicly." Jon Sagara replied: "I think we've all been in that situation before." Crikey! ain't life grand?

        M 1 Reply Last reply
        0
        • P Paul Watson

          I may have your situation wrong but the best way would be to override the OnRender event of the ASCX and spit it out to the provided HtmlWriter. Or a literal as Marcie suggests. What sizing issues are you having? regards, Paul Watson Bluegrass South Africa Chris Maunder wrote: "I'd rather cover myself in honey and lie on an ant's nest than commit myself to it publicly." Jon Sagara replied: "I think we've all been in that situation before." Crikey! ain't life grand?

          M Offline
          M Offline
          Matt Newman
          wrote on last edited by
          #4

          Paul Watson wrote: I may have your situation wrong but the best way would be to override the OnRender event of the ASCX and spit it out to the provided HtmlWriter. I think thats what I may need. Paul Watson wrote: What sizing issues are you having? Outputting it to a label or similar control I have to specify a fixed height so it will render all of my generated html but since the html is dynamic I can't specify the size. [EDIT] I was playing with the OnRender event (which I think is kind of cool) but I realized that it was my user control that was not properly sizing :doh: But the OnRender was what I was looking for.[/EDIT] [EDIT2]It turns out that I hadn't closed some table tags so it was rendering improperly :doh::sigh:[/EDIT2] Matt Newman
          All rise for the honorable Judge Stone Cold Steve Austin - From Dilbert Episode 30

          1 Reply Last reply
          0
          • M Marcie Jones

            A Literal might be better than a Label, since I believe Label's put everything inside of a [span]. Marcie CP Blog[^]

            M Offline
            M Offline
            Matt Newman
            wrote on last edited by
            #5

            Marcie Robillard (Datagrid Girl) wrote: A Literal might be better than a Label, since I believe Label's put everything inside of a [span]. I was looking for something more like overriding OnRender [EDIT]It turns out that I hadn't closed some table tags so it was rendering improperly :doh::sigh:[/EDIT] Matt Newman
            All rise for the honorable Judge Stone Cold Steve Austin - From Dilbert Episode 30

            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