"Make Single Instance Application" in Visual C# 2010 Express - visual-c#-express-2010

I'm using Visual C# 2010 Express, and I'd like my application to be single-instance. Various sources tell me that "Project Properties > Application > Make single instance application" would do such a thing. I can't, however, find this option in VC#2010 Express.
Is it absent from the Express version, or moved, or is it there and I really am just blind?

I was searching for the same thing and sadly, there is no such thing in C#.
You might find what you are looking for here though: http://www.ai.uga.edu/mc/SingleInstance.html

Related

Does the ReSharper API expose ReSharper refactorings?

I'd like to know if the ReSharper API exposes the refactorings that come with the ReSharper plugin. So far I haven't been able to find anything on this in the docs or online. Basically I want to be able to execute several refactorings sequentially (almost like a script). I'm aware that the API allows you to create new refactorings, but I'm not sure if it allows for invoking refactorings that already exist in ReSharper.
Thanks in advance!

What type of project to create for the shared/core code?

I'm just starting out using Xamarin so apologies if this is a very very basic question. I searched around but I couldn't find the information I need.
I've created a blank solution and I've added an Android and an iPhone project to this solution. Both apps/projects build and run okay. Now I want to add a third project which will hold the common code for the two apps.
When I right-click my solution and open up the 'Add new project' window, what project type should I choose for this shared/core code project?
The best practice is to use a Portable Class Library.
You should have a look at the MVVMCross framework,
I've started using it recently and its fantastic.
https://github.com/MvvmCross/MvvmCross

Automated Web Reference Switching in C# project with NAnt

Problem: I have a C# 4.0 project with web references in Visual Studio 2010. I have two sets of web references, but I do not want to use them simultaneously. I want to be able to automatically remove all my current ones, add all the new ones, and then do the equivalent of 'update web reference' on each of them. I'm having a difficult time even finding where to start.
After searching around, I've found NAnt, which looks like it may be able to accomplish what I'm after (with the wsdl command), but I'm in unfamiliar territory.
Question: Is NAnt the right tool for this job? Will I be wasting time if I learn to use it? Is there a simple solution that I'm just not seeing? I'm more just looking for some guidance than a hammered out solution.
If anyone's interested:
After doing more research, I think I'm going to use some combination of
MSBuild,
How to call MSBuild from C#,
and
How do I automatically update a web reference at build time?
I'll update this answer with my solution when I'm done.

How to Add MVC Views in Orchard CMS Custom Module

When I am creating a custom module containing my own Controllers and Views, the default project created by Code Generation creates a project that is like MVC but Visual Studio does not recognize it as an MVC project so it doesn't offer the normal "Add View" tooling as it does in a "real" MVC project.
I have seen posts talking about changing the Project type GUID in the project file but I am hoping there is an alternative to this approach. I have also seen tutorials where the presenter is using Resharper. I am currently not a Resharper user so I am not ready to adopt this approach either.
Are there project templates available? Any Code Generation module features I can take advantage of? I mainly want to find out how people are doing this now to make the development workflow go faster.
Thanks,
Brian
Yes, that's what the code generation tool does, so that we can reduce the Orchard requirements just to ASP.NET 4. Now a module is just a project and a manifest, living in a subfolder of Modules. There is nothing magical about the command-line and it's perfectly fine to create the project from VS. Or you can modify the code generation command so it adds the project type guid at creation. Both choices are valid, you just need to be aware that if there are other users than yourself, you might prevent them from opening the module in VS unless they install the MVC tooling first. That should not be a big problem, but just something to be aware of.

Which development platform should I use for desktop Windows application?

After doing web development for quite a while, I am faced with a new client who wants a simple database application to run outside the interweb.
He is quite adamant about using Microsoft products. "We don't want no steenking open sources" was his stance.
It's been quite a while since I actually did desktop development, and most of my tools are rusty, out of licence, or just plain lost. I have been concentrating lately on L.A.M.P. applications, but that doesn't quite transfer back to the desktop environment.
Some options:
database: MySql (my fav), Access, MSSql
language: C++, VB, PHP, Java, C#
I have been gravitating towards Access/VisualBasic, not because I like it very much, but because it is simple to set up and deploy. A database server (MySql, MsSql) would probably be too hard to deploy/maintain for the novice computer user. Even though from a purist point of view, C++ is the better language, it would take too much effort to bootstrap an application (IMHO). Java is too cumbersome (again IMHO).
The other consideration is cost. Although I can convince him to acquire proper software runtime licences, I probably won't be able to get him to purchase necessary development tools, and certainly the project isn't paying enough to justify substantial purchases which will probably not be used again.
I would appreciate your input on platform selection, development tools and application frameworks, thanx muchly.
Edit 23-May-09
Thank you everyone for your excellent advice.
I have settled on C# Express. So far, I've avoided learning C#, but what's another language?; and I have a whole week to get up to speed.
I am waffling on whether to go with Access or MSSql (Express) database. With Access, I can deploy the database as a stand-alone file, but MSSql requires that the database server be installed. (AFAIK)
The client requires that the application be installed in multiple locations, some of which are mobile and not connected to the interweb. The dicey part is reconciling all the copies of the database, and determining which is the connonical version.
I'd go with the Express editions of C# and MSSQL. Free and easy to use/set up/deploy. Here's a deeper link to some general material specifically about using VS Express editions for Windows applications.
I suggest: Just use Access. It works for small, simple, single user databases. It's not "just a database" it's also a "database application" and "database application development environment" in it's own right. That is: It's ridiculously quick and easy to throw together a db, CRUD forms, and simple reports; and the built-in VBA is handles most business logic, and you can allways call-out to C# dll's if you need to do anything "interesting".
Just tell the customer they need to loan you the production box for the duration of development (fair enough), and that Access (no need to mention which version) is about $200.00.
Customers who don't pay get they get what they ask for, not what they need.
C# + MSAccess/MSSql(express) = Profit.
I don't know exactly your requirements, but I would suggest the following:
If you had the budget:
Visual Studio Professional
MS SQL or Access
DevExpress Components for forms and
database persistence.
If you don't have the budget
Visual Studio Express
MySql
NHibernate or Linq2Entities
WPF or Windows Forms
I don't know why you think another database engine would be easier to administer than MS SQL. There's a free-as-in-beer edition of MS SQL called 'Express' that might suit. It supports all the same DDL and SQL features as the full database engine: in case you need them; it's just limited in size and number of CPUs.
Likewise there are free/express edition of the developer tools, which aren't missing much functionality (most notably perhaps the ability to write an installation program, but there are other free ways to do that). I don't know PHP or Java but if I were given a choice between C++ and C# (I'm familiar with both), I'd say that C# is virtually as capable for most applications except perhaps soft-real-time, and is quite a bit easier and more pleasant.
My preference would be C# with MSSQL Express. You can use the visual studio express edition for your development environment.
Have you considered Delphi or C++Builder there are free versions available.
Microsoft Visual Studio has express editions which are either cheap or free. That said, the choice is obvious: Winforms with C# or Visual Basic .Net (it's just a syntax question) talking to a MySql backend (for cost issues).
Microsoft Winforms is awesome but limited to Windows (Mono notwithstanding). Enjoy the project. It's way more fun than LAMP in my opinion, but not nearly as universal.
Edit: If you have the extra time and patience (of course you would have to eat the hours and not bill the learning time), though C# is brilliant and very mature (even in .Net 1.1 it was :), you may want to write the app in one of the Python variants for .Net. That's what I would do... Python has a huge following and will probably come up sometime in your non-Microsoft future. C# on the other hand... well, if you Mono it could come up, but otherwise, it's like learning Italian: good in Italy, but useless otherwise. (I should know, I'm writing this from my place in Venice...)
C# or VB.Net with SQLite.Net for the database. Pretty much cross platform across the board.
If you need a database local, one file (.dat) or the suggested from one's IDE (berkeleydb) or Sphinxsearch() Relevance sort order with pivot tables are often what users want and no database required only i/o according to document or graphics type.
If you are developing application on desktop. I would say
Scripting Language:ASP.NET(C#)
Database: MS SQL 2005
Server: Windows Server 2003 with IIS 6

Resources