tags:

views:

190

answers:

8

Hello

Before checking out what it's like developping in .Net, I have a few newbie questions:

  1. Can a non-admin user install the .Net framework, whether the original package or any subsequent update required to run a programm? Some of our customers have locked-down XP/Vista hosts, and I'm concerned about installing/updating their computer when we upload a new release that requires updating their version of the .Net framework with the latest ServicePack

  2. Is performance acceptable on regular Joe hardware (ie. doesn't require latest and greatest, power-user hardware)? Our applications are business applications that users leave open all-day, so it doesn't really matter if .Net apps take more time than their Delphi or VBClassic equivalents to start up, but is performance on par once the .Net framework is up and running?

  3. If performance is clearly not as good as eg. compiled Delphi apps, are there known, reliable ways to speed things up?

  4. Since I'm used to writing scripts in Python, is IronPython on par with other .Net languages, or is it more of a hobby language and I should head for VB.Net?


Further questions:

  1. Which IDE should I use? MS' VisualStudio? SharpDevelop? Other? Why?
  2. What makes Mono better than .Net for Windows desktop apps?
  3. In an application, how to check if the user has the right version of the .Net framework and any needed ServicePack? I'd like to avoid having to pack the required .Net framework if it's not needed (ie. if it's not installed and the user has enough admin rights, download and install it before resuming running my app)
  4. What happens if the user isn't logged with enough admin rights to install .Net and/or any needed ServicePack? Is there an obvious error message, so that non-techie users can tell what is wrong?
  5. Is .Net downward-compatible, ie. can an application compiled for 2.0 run on 3.5, or are there tricky incompatibilies, so that it's recommended to install the .Net used to compile the app?

Thank you for any feedback.

+2  A: 

Hi There,

  1. It depends on the users rights. For updates there is also something called ClickOnce technology that will speed up any versioning your program would require, as well as give you a myriad of permission sets on how your program can be run. (Also a note, Vista has .NET2.0 installed already, just some XP machines won't, but you can get it through windows updates - installation here depends on user rights, not .NET persay)
  2. Yes, very much so. As with anything though, Garbage in, Garbage out. .NET is however a managed language and has Garbage Collection, which takes a lot of work off of your plate in development.
  3. N/A
  4. Misunderstood this point first time round. Personally, IronPython is out there and working, but learning may be harder than something like VB.NET/C#

Hope this helps.

Kyle Rozendo
Thanks for the feedback. For #4, I mentionned IronPython (http://www.codeplex.com/wikipage?ProjectName=IronPython), not C#.
OverTheRainbow
Yea, that was my mistake (misread), already updated, hehe.
Kyle Rozendo
Do you have any reference for your first answer? This seems not correct in my opinion. The .NET Framework setup will modify system files, e.g. write to %SYSTEMROOT% and to the HKLM registry hive. Both would require administrative privileges. Or is there a version that installs totally to the user's AppData folder?
0xA3
Refer to the end of the sentence. It depends on the users rights, a lot of users will be able to without issues though (Due to correct permissions).
Kyle Rozendo
Vista comes with .NET 3, even.
Joey
Just mentioned 2.0 as its the "most" compatible between XP and Vista :) "most" meaning how scary it is how people do not have 2.0 on XP.
Kyle Rozendo
C# has much better support over IronPython, I would consider that a great advantage when starting from scratch.
Groo
@Kyle: So when referring to the end of the sentence, the answer should be "No, they can't" ;-)
0xA3
Shall edit for less confusion.
Kyle Rozendo
A: 

To answer some of your questions.

  1. Obvously the logged on user must have rights to install / uninstall software, but this is the same for any software on the machine, not a .net specific issue
  2. Performance is highly acceptable, way better than Java, and just as good (if not better) than regular executables
  3. Performance is acceptable, but you get ways to convert .net assemblies into regular .exe's this way they will not require the .net framework to run
  4. Go C# if possible or vb.net (lots more code samples, and way more main stream)
JL
Thanks.For #3: What tool would you recommend to statically compile a .Net application, and are there drawbacks to shipping applications that way?For #4: I though so. I guess C€/VB.Net are really the only languages with significant traction.
OverTheRainbow
When you compile .NET natively, you end up having to cater for different machine configurations yourself. The .NET framework chooses ideal compiling in the JIT which means you don't necessarily have to worry about this sort of thing. This is what I have read.
Kyle Rozendo
#2 is probably disputable, #3 is dead-wrong. If you are referring to `ngen`, then all you do is create native code. The dependency for the framework remains.
Joey
#3 - No, you will always need to have .net installed.
Groo
+2  A: 
  1. No. System files need modifying, and as such the framework itself can only be installed by a privileged user. Applications that run on .NET don't require special permissions to install or update though.

  2. Performance of .NET applications isn't really an issue for business applications. Yes, they are on par with Delphi, VB pre .NET and Java.

  3. Same as with any application: profiling and optimising. Profiling .NET applications can actually be very easy given the amount of metadata that can be (and is by default) stored in the actual executable for the profiler to use.

  4. No comment really, since I havn't used any of the three much.

Matthew Scharley
Thanks much for the great feedback everyone. Google tells me that to get started with VB.Net, I need: .Net framework + SDK (compiler) + VisualStudio (IDE). Is this correct? Are there add-on's/alternatives I should know about (eg. SharpDevelop open-source IDE)?
OverTheRainbow
IMO, SharpDevelop is good for mono development on Linux, but don't use it on Windows. Go for Visual Studio Express instead. As far as what you need... If you install Visual Studio, you have everything you need.
Matthew Scharley
A: 
  1. Never tried this but it's easy enough for you to test.
  2. Yes, it is.
  3. You can ngen apps but it's rarely necessary.
  4. Can't help you with this one. However, some might say that VB.net is a hobby language :-) If you're starting from scratch, look to see what sample code is available in the various .NET languages in your problem domain. Seriously, have a look. VB.Net should be easier to read than C# because it uses lots of nice words instead of e.g. nasty braces {}. But once you're into it, C# is very easy to read and a lot less cluttered than verbose old VB.
serialhobbyist
You'll find that the majority of articles, forum answers, code samples, etc... are in C#. We have to use VB where I work and sometimes it's a pain to convert some solutions from C# to VB, especially for some constructs that don't exist in VB (yet.) My advice to anyone wondering which to pick is C#. The only thing I like better with VB is that the VS2008 editor is much better at auto-completing and formatting the code.
MetalMikester
There's a lot of ASP.NET stuff in VB because of the people that switched from VB6 to VB.NET. There are other problem domains like identity management where VB dominates.
serialhobbyist
A: 
  1. I think you do need admin rights to install the framework. But both current XP and Vista should come with version 2.0 of the framework which is a good target for new applications.

  2. Performance is acceptable for everything but graphics-intensive games.

  3. It's really not needed.

  4. You can use IronPythin for application development and I know of at least one commercial shop that does it (http://www.resolversystems.com/), but I would recommend C# or VB.NET. Personally, I like Delphi Prism (http://www.embarcadero.com/products/delphi-prism). If you are into Delphi, maybe that's the way to go?

Andrew J. Brehm
XP doesn't come with .NET. Remember that .NET dates back to 2002, while XP is from 2001.
Joey
"Current XP"... I assume that any large organisation would have upgraded to SP2 by now!
Andrew J. Brehm
+1  A: 

IronPython doesn't have the same level of support as C# and VB. Still, it works exceptionally well, and if you like Python that's a win.

orip
+4  A: 

Can a non-admin user install the .Net framework, whether the original package or any subsequent update required to run a programm?

Generally speaking, no. For development, you're definitely going to need the framework installed to use most tools, and you'll need administrative access for that. That said, there are some technical workarounds that enable you to deploy a single application without having the .NET framework on the target computer.

Is performance acceptable on regular Joe hardware (ie. doesn't require latest and greatest, power-user hardware)?

Yes, very much so.

If performance is clearly not as good as eg. compiled Delphi apps, are there known, reliable ways to speed things up?

There's plenty of introspection, profiling, and optimization tools available -- CLR Profiler, dotTrace, Reflector, et cetera. Somewhat of a moot point, since most .NET programs are on par (or better than) their counterparts, as noted above.

Since I'm used to writing scripts in Python, is IronPython on par with other .Net languages, or is it more of a hobby language and I should head for VB.Net?

Although the implementation is relatively mature and it's reached the "it just works" stage, the tools supporting IronPython aren't as robust as the other languages in the .NET family. For a beginner, you might want to try C# just to get your feet wet, since the toolsets will be well developed and you'll have lots of examples to go on. That said, I routinely use IronPython and IronRuby on production projects. Good stuff!

John Feminella
+1 Good point, profiling and disassembling support is excellent for .Net code. Newer versions of reflector (EAP) are even able to get the source code during debugging, from an assembly you don't have a source code for.
Groo
A: 

To avoid creating a new question, I'll post a few more questions I have on .Net/VB.Net:

  1. Which IDE should I use? MS' VisualStudio? SharpDevelop? Other? Why?

  2. What makes Mono better than .Net for Windows desktop apps?

  3. In an application, how to check if the user has the right version of the .Net framework and any needed ServicePack? I'd like to avoid having to pack the required .Net framework if it's not needed (ie. if it's not installed and the user has enough admin rights, download and install it before resuming running my app)

  4. What happens if the user isn't logged with enough admin rights to install .Net and/or any needed ServicePack? Is there an obvious error message, so that non-techie users can tell what is wrong?

  5. Is .Net downward-compatible, ie. can an application compiled for 2.0 run on 3.5, or are there tricky incompatibilies, so that it's recommended to install the .Net used to compile the app?

Thank you.

OverTheRainbow
You can update your question
John Nolan