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. C#
  4. Seeking advice for learning how to create small LOB applications in C#

Seeking advice for learning how to create small LOB applications in C#

Scheduled Pinned Locked Moved C#
csharpwpfdatabasesql-server
7 Posts 4 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.
  • D Offline
    D Offline
    Duke Carey
    wrote on last edited by
    #1

    Background: Lots of Excel modelling (20+ years), lots of Excel VBA, plenty of ad hoc T-SQL, and some rudimentary WinForms apps with VB.Net. Have begun the transition from VB to C#, and have learned enough XAML to be dangerous. In our department we occasionally need to collect user input for some relatively simple SQL Server databases - with typical CRUD activities. These will USUALLY be short term initiatives, so the effort that goes into creating the apps can't be too great. I'll be a part time 'programmer' creating these apps. I'm looking at WPF as the vehicle for these apps, and it sure seems that MVVM can simplify the UI a great deal. I think I can handle the Views and ViewModels. Where I am struggling, though, is finding relevant examples on the Model aspect. It seems examples are either too simple, with a local XML file providing the data for a class or two, or they are (to me) too complex, with ISomeObjectRepository and SomeObjectRepository, IUnitOfWork and UnitOfWork, etc. Much as I would like to understand all this "stuff," programming these apps is not my day job, so I need some straightforward examples/tutorials for building reasonably reliable apps. I'm also looking for advice on whether working through learning MVVM for its occasional use is warranted. Am I better off abandoning MVVM and simply binding the UI to the classes that EF or LinqToSQL create? Or, is somebody in my position really best advised to wait until LightSwitch is out of beta? Thanks in advance!

    N S 2 Replies Last reply
    0
    • D Duke Carey

      Background: Lots of Excel modelling (20+ years), lots of Excel VBA, plenty of ad hoc T-SQL, and some rudimentary WinForms apps with VB.Net. Have begun the transition from VB to C#, and have learned enough XAML to be dangerous. In our department we occasionally need to collect user input for some relatively simple SQL Server databases - with typical CRUD activities. These will USUALLY be short term initiatives, so the effort that goes into creating the apps can't be too great. I'll be a part time 'programmer' creating these apps. I'm looking at WPF as the vehicle for these apps, and it sure seems that MVVM can simplify the UI a great deal. I think I can handle the Views and ViewModels. Where I am struggling, though, is finding relevant examples on the Model aspect. It seems examples are either too simple, with a local XML file providing the data for a class or two, or they are (to me) too complex, with ISomeObjectRepository and SomeObjectRepository, IUnitOfWork and UnitOfWork, etc. Much as I would like to understand all this "stuff," programming these apps is not my day job, so I need some straightforward examples/tutorials for building reasonably reliable apps. I'm also looking for advice on whether working through learning MVVM for its occasional use is warranted. Am I better off abandoning MVVM and simply binding the UI to the classes that EF or LinqToSQL create? Or, is somebody in my position really best advised to wait until LightSwitch is out of beta? Thanks in advance!

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      Duke Carey wrote:

      These will USUALLY be short term initiatives

      Given this I would hesitate on using WPF. It seems it would create an issue of users having many apps on their systems that will be outdated and attempting to enter data that may no longer be valid or useful. I would consider a web interface where the apps could be easily taken out of service after the initiative passed, or possible ClickOnce deployment with the app run from a server. If the data structure is relatively simple as you say I would say MVVM isn't worth the effort at this point. However, you would certainly want to expend some thought on creating a reusable architecture. Is InfoPath and option for you?


      I know the language. I've read a book. - _Madmatt

      D 1 Reply Last reply
      0
      • N Not Active

        Duke Carey wrote:

        These will USUALLY be short term initiatives

        Given this I would hesitate on using WPF. It seems it would create an issue of users having many apps on their systems that will be outdated and attempting to enter data that may no longer be valid or useful. I would consider a web interface where the apps could be easily taken out of service after the initiative passed, or possible ClickOnce deployment with the app run from a server. If the data structure is relatively simple as you say I would say MVVM isn't worth the effort at this point. However, you would certainly want to expend some thought on creating a reusable architecture. Is InfoPath and option for you?


        I know the language. I've read a book. - _Madmatt

        D Offline
        D Offline
        Duke Carey
        wrote on last edited by
        #3

        Thanks for taking the time to answer Mark. Your comment about MVVM resonates, but I've already dummied up/prototyped one WPF app that, immediately after a demo, required significant changes and all most of the code behind had to be scrapped (probably tells you something about my coding skills). Thus, the command structure and ViewModels tug at me as being a real benefit. I guess what was left unstated in the original question was that using WPF first might allow us to easily migrate to Silverlight, if we can get the corporate folks to grant us access to a server. That's all locked down pretty tight right now, and I feel I'm viewed as an anarchist for asking for server access. So, the deployment of any app - WinForm, WPF, or web-based - is fraught with problems of one sort or another. InfoPath was tried once (not my effort) but, on the one hand, the data demands outstripped the SharePoint version's abilities and, on the other, few people have it on their desktops. The SharePoint hosted form had an issue with the data not fitting into a simple list format, and in our apps we'll be dealing with 5 or 6 related tables. I've looked at some of the videos for LightSwitch and it looks as though it will allow somebody like me to quickly create smaller apps. I just worry that some business requirement will come up will be JUST beyond the reach of what LightSwitch can do, and then I'd be back to square one, so it seemed best to ask for help here.

        N realJSOPR 2 Replies Last reply
        0
        • D Duke Carey

          Thanks for taking the time to answer Mark. Your comment about MVVM resonates, but I've already dummied up/prototyped one WPF app that, immediately after a demo, required significant changes and all most of the code behind had to be scrapped (probably tells you something about my coding skills). Thus, the command structure and ViewModels tug at me as being a real benefit. I guess what was left unstated in the original question was that using WPF first might allow us to easily migrate to Silverlight, if we can get the corporate folks to grant us access to a server. That's all locked down pretty tight right now, and I feel I'm viewed as an anarchist for asking for server access. So, the deployment of any app - WinForm, WPF, or web-based - is fraught with problems of one sort or another. InfoPath was tried once (not my effort) but, on the one hand, the data demands outstripped the SharePoint version's abilities and, on the other, few people have it on their desktops. The SharePoint hosted form had an issue with the data not fitting into a simple list format, and in our apps we'll be dealing with 5 or 6 related tables. I've looked at some of the videos for LightSwitch and it looks as though it will allow somebody like me to quickly create smaller apps. I just worry that some business requirement will come up will be JUST beyond the reach of what LightSwitch can do, and then I'd be back to square one, so it seemed best to ask for help here.

          N Offline
          N Offline
          Not Active
          wrote on last edited by
          #4

          Duke Carey wrote:

          is fraught with problems of one sort or another.

          It goes without saying that these types of issues need to be corrected, or mitigated, before any project has a chance at success.

          Duke Carey wrote:

          some business requirement will come up will be JUST beyond the reach of what LightSwitch can do

          Yes. And that limit will come very quickly. Good luck


          I know the language. I've read a book. - _Madmatt

          1 Reply Last reply
          0
          • D Duke Carey

            Background: Lots of Excel modelling (20+ years), lots of Excel VBA, plenty of ad hoc T-SQL, and some rudimentary WinForms apps with VB.Net. Have begun the transition from VB to C#, and have learned enough XAML to be dangerous. In our department we occasionally need to collect user input for some relatively simple SQL Server databases - with typical CRUD activities. These will USUALLY be short term initiatives, so the effort that goes into creating the apps can't be too great. I'll be a part time 'programmer' creating these apps. I'm looking at WPF as the vehicle for these apps, and it sure seems that MVVM can simplify the UI a great deal. I think I can handle the Views and ViewModels. Where I am struggling, though, is finding relevant examples on the Model aspect. It seems examples are either too simple, with a local XML file providing the data for a class or two, or they are (to me) too complex, with ISomeObjectRepository and SomeObjectRepository, IUnitOfWork and UnitOfWork, etc. Much as I would like to understand all this "stuff," programming these apps is not my day job, so I need some straightforward examples/tutorials for building reasonably reliable apps. I'm also looking for advice on whether working through learning MVVM for its occasional use is warranted. Am I better off abandoning MVVM and simply binding the UI to the classes that EF or LinqToSQL create? Or, is somebody in my position really best advised to wait until LightSwitch is out of beta? Thanks in advance!

            S Offline
            S Offline
            SledgeHammer01
            wrote on last edited by
            #5

            As another guy in this thread said, if you are just doing small "one-off" apps, MVVM definitely isn't worth the trouble. Actually, let me rephrase that: *PROPER* MVVM isn't worth the trouble for small "one-off" apps. Lots of guys say they are doing MVVM, but when you look at their code, its more like "make believe MVVM" since they've broken a lot of MVVM tennants. I'm not sure where you fall in that category (no offense intended), but if you aren't doing MVVM right, or are just doing it because "its what the cool kids are doing", you are asking for trouble and hair pulling. You should only use MVVM where its appropriate and understand why you are using it. If your MVVM infrastructure is larger then your app "u r doing it wrong!!" :). I'm even going to go a step further... for small "one-off" apps, why even bother with WPF? WPF is intended for rich customized applications. If you are just doing a cookie cutter form with stock controls, WPF ain't worth the hassle. Lots of stupid small things that would take you one line of code in Winforms would take pages and pages of code in WPF. WPF is a huge time saver in certain areas, but its also a massive time killer in other areas. As for WPF vs. Silverlight... its straight forward to go from Silverlight to WPF since Silverlight is a subset of WPF. Not so easy to go the other way.

            1 Reply Last reply
            0
            • D Duke Carey

              Thanks for taking the time to answer Mark. Your comment about MVVM resonates, but I've already dummied up/prototyped one WPF app that, immediately after a demo, required significant changes and all most of the code behind had to be scrapped (probably tells you something about my coding skills). Thus, the command structure and ViewModels tug at me as being a real benefit. I guess what was left unstated in the original question was that using WPF first might allow us to easily migrate to Silverlight, if we can get the corporate folks to grant us access to a server. That's all locked down pretty tight right now, and I feel I'm viewed as an anarchist for asking for server access. So, the deployment of any app - WinForm, WPF, or web-based - is fraught with problems of one sort or another. InfoPath was tried once (not my effort) but, on the one hand, the data demands outstripped the SharePoint version's abilities and, on the other, few people have it on their desktops. The SharePoint hosted form had an issue with the data not fitting into a simple list format, and in our apps we'll be dealing with 5 or 6 related tables. I've looked at some of the videos for LightSwitch and it looks as though it will allow somebody like me to quickly create smaller apps. I just worry that some business requirement will come up will be JUST beyond the reach of what LightSwitch can do, and then I'd be back to square one, so it seemed best to ask for help here.

              realJSOPR Offline
              realJSOPR Offline
              realJSOP
              wrote on last edited by
              #6

              Duke Carey wrote:

              So, the deployment of any app - WinForm, WPF, or web-based - is fraught with problems of one sort or another.

              I'd like to be there when you tell them your Silverlight app/WCF service needs cross-domain permissions. The looks on the security guys' faces would be priceless... :)

              .45 ACP - because shooting twice is just silly
              -----
              "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
              -----
              "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

              D 1 Reply Last reply
              0
              • realJSOPR realJSOP

                Duke Carey wrote:

                So, the deployment of any app - WinForm, WPF, or web-based - is fraught with problems of one sort or another.

                I'd like to be there when you tell them your Silverlight app/WCF service needs cross-domain permissions. The looks on the security guys' faces would be priceless... :)

                .45 ACP - because shooting twice is just silly
                -----
                "Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997
                -----
                "The staggering layers of obscenity in your statement make it a work of art on so many levels." - J. Jystad, 2001

                D Offline
                D Offline
                Duke Carey
                wrote on last edited by
                #7

                John Simmons / outlaw programmer wrote:

                I'd like to be there when you tell them your Silverlight app/WCF service needs cross-domain permissions.

                JSOP - I was kinda hoping you might carry the water for me on that one, since you could 'splain it so much better than me!

                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