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. Pulling data from interface

Pulling data from interface

Scheduled Pinned Locked Moved ASP.NET
question
4 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.
  • O Offline
    O Offline
    oPhoenixo
    wrote on last edited by
    #1

    Is there a cleaner way to pull a lot of data from a form for calculations? I feel like I have a lotta ugly tryparse stuff going on. Do people just pull it in one go? I have like 40 controls a user can change (trust me, it can't be helped) and on recalc its a lot of pull, calculate, put back. Seems horribly messy.

    D J 2 Replies Last reply
    0
    • O oPhoenixo

      Is there a cleaner way to pull a lot of data from a form for calculations? I feel like I have a lotta ugly tryparse stuff going on. Do people just pull it in one go? I have like 40 controls a user can change (trust me, it can't be helped) and on recalc its a lot of pull, calculate, put back. Seems horribly messy.

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

      So I guess you don't want to put Javascript in your form to do the calculations ? I have a fairly complex form with the same problem. I have 2 routines, one to map the screen to internal values and another to map the internal values to the screen. Ugly. Yes; but it works and it is straight forward.

      O 1 Reply Last reply
      0
      • D David Mujica

        So I guess you don't want to put Javascript in your form to do the calculations ? I have a fairly complex form with the same problem. I have 2 routines, one to map the screen to internal values and another to map the internal values to the screen. Ugly. Yes; but it works and it is straight forward.

        O Offline
        O Offline
        oPhoenixo
        wrote on last edited by
        #3

        Not especially no... for one Javascript still isn't as 'native' to me as a language. I imagine I'd have to learn some jquery to handle any of the database pulled information? using javascript would at least get away from the parsing due to the weak typing though eh?

        1 Reply Last reply
        0
        • O oPhoenixo

          Is there a cleaner way to pull a lot of data from a form for calculations? I feel like I have a lotta ugly tryparse stuff going on. Do people just pull it in one go? I have like 40 controls a user can change (trust me, it can't be helped) and on recalc its a lot of pull, calculate, put back. Seems horribly messy.

          J Offline
          J Offline
          jkirkerx
          wrote on last edited by
          #4

          I have a huge product editor, with over 80 fields. I'm on my 8th generation of it now. The last update I made was to create a huge Javascript object of the entire thing, and small saves just update the object in the DOM, Full saves use $ajax to update the database. Validation is on the fly using blur When clicking through the tabs, the data is loaded from the object. It took me a 2 week to write, over 10K lines of Javascript, but so far so good, no complaints after 3 months of running it. It's a combination of Javascript and JQuery, but mostly Javascript.

          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