Blog Archives

Video Tutorial – Asynchronous Programming in .NET 4.5 (Task, async and await) – C# 5.0

Microsoft_DotNET_Logo

This is a great introduction video for Async Programming in .net 4.5 making multi threaded application super easy and bug free. In below tutorial You will learn following concepts Using Task Using Async and Await Keywords in .net 4.5

Tagged with: , ,
Posted in .net, C#, VB.net

How to call StoredProcedure in LightSwitch for custom search screen validation

lightswitch-add-reference0

I recently came across requirement where user asked to perform complex validation before query is fired to return search screen data. So here is my code snippet you can call inside yourqueryname_ProcessQuery Create stored procedure for validation First thing we

Tagged with: ,
Posted in .net, LightSwitch, VB.net

How to provide custom button for search in LightSwitch

lightswitch-disable-auto-refresh

Recently someone asked me how to change default LightSwitch behavior for Search screen. Which is press enter for search. But what if you want to provide Button which user can Press to search data? Here is step-by-step info on how

Tagged with: ,
Posted in .net, LightSwitch, VB.net

How to show delete confirmation in LightSwitch

lightswitch-row-delete-confirm

If you want to ask user before deleting record then write the following code in your screen code editor. Namespace LightSwitchApplication Public Class EditableCustomersGrid Private Sub gridDeleteSelected_Execute() ' Write your code here. If ShowMessageBox("Are you sure you want to delete

Tagged with: ,
Posted in .net, LightSwitch, VB.net

How to Read Locked file in VB or C#

Have you ever got this error “File is being used by another process” Just try this create simple textfile on disk (e.g. mydata.txt) and open it with Excel… This way its locked (This is my trick to mimic locking of file) Now try

Tagged with: ,
Posted in .net, C#, VB.net

Bulk Load ADO.net DataTable to SQL Server Table

This code snippet will make your life super easy if you have similar need what I had. Here is simple problem… If you have DataTable(s) or You have DataSet with Multiple DataTables and You want to Insert all records to

Tagged with: , , , , ,
Posted in .net, SQL Server

VB.net or C# – Which language should you pick for future

Zemanta Related Posts Thumbnail

I get this question many times. And this question starts religious war… My language is better than yours !!! Lets not get into what language is better than other.  Lets talk whats the strategy Microsoft’s Compiler  Services division heading towards Microsoft

Tagged with: , ,
Posted in .net