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. How to calculate number of lines?

How to calculate number of lines?

Scheduled Pinned Locked Moved ASP.NET
htmldatabasehelptutorialquestion
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.
  • G Offline
    G Offline
    Gaurav Aroraa
    wrote on last edited by
    #1

    Issue:b> Want to calculate number of lines per page approx. 60 lines per page, while printing from HTML data stored in a Hidden field. Description: In my project I have created html from database and get it into an hidden field from code behind. Now, at client side I am fetching the data according to the conditions. Now, I want to count the sixty lines per page. Can anyone tell me the solution?

    B D 2 Replies Last reply
    0
    • G Gaurav Aroraa

      Issue:b> Want to calculate number of lines per page approx. 60 lines per page, while printing from HTML data stored in a Hidden field. Description: In my project I have created html from database and get it into an hidden field from code behind. Now, at client side I am fetching the data according to the conditions. Now, I want to count the sixty lines per page. Can anyone tell me the solution?

      B Offline
      B Offline
      Blue_Boy
      wrote on last edited by
      #2

      Check this[^],it's only idea how can you find solution. By the way why you made all underline and bold your question?


      I Love T-SQL "Don't torture yourself,let the life to do it for you." If my post helps you kindly save my time by voting my post. www.aktualiteti.com

      G 1 Reply Last reply
      0
      • G Gaurav Aroraa

        Issue:b> Want to calculate number of lines per page approx. 60 lines per page, while printing from HTML data stored in a Hidden field. Description: In my project I have created html from database and get it into an hidden field from code behind. Now, at client side I am fetching the data according to the conditions. Now, I want to count the sixty lines per page. Can anyone tell me the solution?

        D Offline
        D Offline
        David Mujica
        wrote on last edited by
        #3

        I think I understand your question. Let's say you read 100 lines from your database and you want to display them on a page with a maximum of 60 lines per page. Try something like this:

        Lines = 100
        Page = 0
        PageSize = 60

        While Lines > PageSize
        Page = Page + 1
        ... Load your HTML PageData ...
        Lines = Lines - (PageSize)
        End

        Page = Page + 1

        G 1 Reply Last reply
        0
        • B Blue_Boy

          Check this[^],it's only idea how can you find solution. By the way why you made all underline and bold your question?


          I Love T-SQL "Don't torture yourself,let the life to do it for you." If my post helps you kindly save my time by voting my post. www.aktualiteti.com

          G Offline
          G Offline
          Gaurav Aroraa
          wrote on last edited by
          #4

          I want to know number lines while printing on the paper. To know the number of lines in a file is hardly helpful in my case. I have marked and underline my question to better understanding.

          1 Reply Last reply
          0
          • D David Mujica

            I think I understand your question. Let's say you read 100 lines from your database and you want to display them on a page with a maximum of 60 lines per page. Try something like this:

            Lines = 100
            Page = 0
            PageSize = 60

            While Lines > PageSize
            Page = Page + 1
            ... Load your HTML PageData ...
            Lines = Lines - (PageSize)
            End

            Page = Page + 1

            G Offline
            G Offline
            Gaurav Aroraa
            wrote on last edited by
            #5

            No, actually I have all html data in an hidden fields. Your solution is a good for static data but I need to print rendered data

            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