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. General Programming
  3. Design and Architecture
  4. how to separate

how to separate

Scheduled Pinned Locked Moved Design and Architecture
asp-netregexxmlarchitecturetutorial
2 Posts 2 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.
  • N Offline
    N Offline
    netJP12L
    wrote on last edited by
    #1

    My xml file stores some data about different types of shapes and I want to load only those shapes which are being display, if a Next button is clicked it displays a shape if clicked again displays another shape. A shapecontrol may have picturebox control so how can I separate the shape control from its data. I know that i have to look into MVC pattern and have read about it but can't really figure out how to put together to get the result i want. Basially i want to build like Ms power points. If power point we can add differnt kidns of objects and can view there raw data like height,width. Basially, i think controls are separted from data. That's what i want to

    M 1 Reply Last reply
    0
    • N netJP12L

      My xml file stores some data about different types of shapes and I want to load only those shapes which are being display, if a Next button is clicked it displays a shape if clicked again displays another shape. A shapecontrol may have picturebox control so how can I separate the shape control from its data. I know that i have to look into MVC pattern and have read about it but can't really figure out how to put together to get the result i want. Basially i want to build like Ms power points. If power point we can add differnt kidns of objects and can view there raw data like height,width. Basially, i think controls are separted from data. That's what i want to

      M Offline
      M Offline
      Matthew Faithfull
      wrote on last edited by
      #2

      Obviously I can't post a complete solution, I've worked on the equivalent of MS PowerPoint and it was years of work. In general I would say to separate controls from data start by forgetting about the controls. Just think of the data, how to store it, retrieve it, access it and structure it. Then think about the controls as something you do with the data. When you do that you'll suddenly find you need data you didn't think of before. Add that to your original list and start over with getting your data structures right. Only when you switch to thinking about the controls and find all the data you need is readily available from your containers in a fast and safe manner then start on the controls for real. The trick, if there is one, to a GUI heavy application is to do as little as possible in the GUI code and as much as possible in the data layer. :)

      Nothing is exactly what it seems but everything with seems can be unpicked.

      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