Questions tagged [lightswitch-2012]

Microsoft Visual Studio 2012 LightSwitch is a rapid application development tool for creating data centric Silverlight and HTML applications.

LightSwitch is a designer-based addition to Visual Studio 2012 to assist in working with data-centric services and applications. When working with a LightSwitch project, the Visual Studio IDE changes to a development environment with only three main editors (in so-called “Logical mode”): the Entity Designer, the Query Designer and the Screen Designer. These editors focus on getting results quickly by being extremely intuitive, fast and easy to use. This adds some obvious benefits to the life of a LightSwitch developer:

  • First, it hides the plumbing (the repetitive code that’s typically associated with the development of these information systems). Easy-to-use editors mean fast development, fast development means productive developers and productive developers mean more value to the business. Or, as Scott Hanselman would say, “The way that you scale something really large, is that you do as little as possible, as much as you can. In fact, the less you do, the more of it you can do” (see Scott Hanselman's Personal Productivity Tips).

  • Second, and perhaps most important, nontechnical people, ranging from functional analysts to small business owners to Microsoft Access or Microsoft Excel “developers”—often referred to as citizen developers—who know the business inside out, can step in and help develop the application or even develop it entirely. The editors hide technological choices from those who prefer to avoid them and silently guide the application designer to apply best practices, such as encapsulating the domain logic in reusable domain models, keeping the UI responsive by executing business logic on a thread other than the UI thread, or applying the Model-View-ViewModel (MVVM) development pattern in the clients.

  • Finally, these editors actually don’t edit classes directly. Instead, they operate on XML files that contain metadata (LightSwitch Markup Language), which is then used by custom MSBuild tasks to generate code during compilation. This effectively frees the investment made in business logic from any technological choices. For example, a LightSwitch project that was made in version 1.0 would use WCF RIA Services for all communication between client and server, whereas that same project now compiles to use an Open Data Protocol (OData) service instead (more on OData later). This is about as adaptive to the ever-changing IT landscape as an application can get.

Source: Shape Up Your Data with Visual Studio LightSwitch 2012

136 questions
27
votes
3 answers

How to get all the females?

I would like to get the gender for calculations, for example the male and female options are in one column. I would like to get all male or all female for calculation. I have a "computed property" which gives me list of all the items along with…
4
votes
2 answers

How can I use MySQL with Visual Studio 2012 Lightswitch?

How can I use MySQL with Visual Studio 2012 Lightswitch? I want to use Amazon AWS RDS for the MySQL server. I'm getting an error: Failed to find or load the registered .Net Framework Data Provider.
3
votes
1 answer

Installing a LightSwitch 2-tier application for "all users"?

I've developed a LightSwitch 2-tier application (desktop application) for a client. The client now wants to install the application on a Citrix server, and therefore it is necessary for the application to be available for all users on the…
Dan
  • 10,480
  • 23
  • 49
3
votes
0 answers

LightSwitch Object Reference Issue during migration from VS2012 Update 3 to VS2013 Update 1 RC

I have a LightSwitch project that compiles and runs in VS2012 Update 3 with no problems. When attempting to migrate the project to VS2013 Update 1 RC the following error is generated: myprojectname.lsxproj: Object reference not set to an instance…
3
votes
0 answers

Lightswitch and Entity Framework

I am trying to build a simple db application. I learned EF code first approach and liked it. However I don't want to deal with interface design. Lightswitch seems to be right tool to create my CRUD screens easily. What I understand is I can easily…
Hasan
  • 2,444
  • 3
  • 30
  • 44
3
votes
1 answer

Root element is missing when trying to Publish

It has been a while since I've published my app to Azure. During that time frame, I've upgraded my system from 32-bit to 64-bit meaning a fresh install of Windows and Visual Studio. And Visual Studio Update 3 came out and was applied. When I went to…
3
votes
2 answers

Lightswitch - Hiding Columns

FindControl seems to only reference the name of the grid, not the column name inside the grid. I can't find any documentation or examples regarding FindControlInCollection either. I don't have any sophisticated logic to wrap this in at this point.…
weweber3
  • 31
  • 2
3
votes
1 answer

Saving images in Azure Blob Storage using Lightswitch 2012

I have a lightswitch application which currently stores all data in SQL Azure - including images. But I would like to keep the images separately in Azure Blob Storage and all non-binary data as it is. So the outcome of saving an entity in the…
3
votes
1 answer

Reuse generic command in multiple lightswitch screens

I am designing a LightSwitch 2012 application to manage requests, and I want to be able to update the request state with the same reusable code across all of my screens. For example, A user can change a request state in the approval screen, the…
DTreth
  • 87
  • 5
2
votes
1 answer

LightSwitch: Distributed transactions on Azure

Dears, I have scenarios where I have to perform updates on the intrinsic database of LightSwitch and call some SQL stored procedures in the save pipeline all in ONE TRANSACTION, such that if an error happened in the LS save pipeline then my stored…
2
votes
1 answer

DataGrid foreach entity error

In this _ControlAvailable I am getting an error. In my entity "InsuranceQuotation c" (which is my db GridView) I have access to "c.mYear" which is a column containing dates. This from db gives me "InsuranceQuotation.mYear" like this: void…
Xdrone
  • 781
  • 1
  • 11
  • 21
2
votes
1 answer

How to customize the global navigation menu in LightSwitch - Visual Studio 2013

I have created one LightSwitch Web App HTML client using C# in Visual Studio 2013. I have connected to the External DB and loaded around 10 tables and created 3 screen templates (Browse, View and Add/Edit) for each table. while running my…
2
votes
2 answers

LightSwitch Users and Roles management option is not appear

After deploy my LightSwitch HTMLClient application with forms authentication and Add desktop client in order to manage users and roles, I go to http://mylssite.net/app/desktopclient and then, when I loggin to the administrator site only reset my…
jcamacho
  • 818
  • 2
  • 12
  • 25
2
votes
1 answer

How to detect add or edit mode in HTML5 Lightswitch client?

How do you detect if, when using LightSwitch, the detail page is in Add or Edit mode? I want to change the title of the screen from AddEdit Customer to either 'Add Customer' or 'Edit Customer'. I can get screen.detail.dispayName = "Something". i…
buttercup
  • 1,096
  • 16
  • 37
2
votes
0 answers

Integrate Lightswitch HTML deployed as Web Site with Windows Azure Active Directory

I'm trying to implement Windows Authentication in a newly created Lightswitch HTML application hosted in Windows Azure as a Web Site. After creating the Active Directory and the application and following the steps provided in the blog entry refered…
1
2 3
9 10