Welcome to MSDN Blogs Sign in | Join | Help

August 2007 - Posts

Use Stored Procedures when you can for efficiency

In this post ( Install Northwind for SQL Express and use Visual Studio and DLINQ to query it ) I posted a fairly complex SQL command. Of course, it’s important to keep in mind that a more efficient way of executing this query may be by keeping all the

Install Northwind for SQL Express and use Visual Studio and DLINQ to query it

SQLExpress is free and comes with Visual Studio, but the sample Northwind database isn’t included. You can download sample databases Northwind and Pubs from http://www.microsoft.com/downloads/details.aspx?FamilyID=06616212-0356-46a0-8da2-eebc53a68034&displaylang=en
Posted by Calvin_Hsia | 5 Comments
Filed under: , ,

Linq Queries for .Net Framework members

How many members in the .Net framework contain the string ‘file” ? Make a query like this: Dim q As Object q = From Assembly In AppDomain.CurrentDomain.GetAssemblies _ From typ In Assembly.GetTypes _ From Member In typ.GetMembers _ Where Member.Name.ToLower.Contains(
Posted by Calvin_Hsia | 3 Comments
Filed under: ,

C# and Fox versions of Cool Linq Query

In my prior post ( Cool Linq Query ) I promised a C# and Fox versions of a query to sort all the “Words” found in many files in a C++ project and sort them by frequency of occurrence. The C# version: it’s almost the same as the VB version. Try typing
Posted by Calvin_Hsia | 5 Comments
Filed under: , ,

Cool Linq Query

Now that Visual Studio 2008 Beta 2 is out the door, I can write about some cool Linq Queries, and you can run them. Foxpro has had Language Integrated Query (Linq) in the form of embedded SQL statements (Create Table/Select/Update/Insert/Delete/Alter
Posted by Calvin_Hsia | 6 Comments
Filed under: ,

It's easy to resize your disk volumes on Vista

On one of my Vista machines, I have a 140G hard drive partitioned into C (20g), D (80G) and E (40g). Drive E was getting full, and I wanted to make it bigger. Isn’t it ironic that in the year 2007, we still are using letters of the alphabet to refer to
Posted by Calvin_Hsia | 1 Comments
Filed under:

Add an interactive map to your web page

It’s pretty cool to play with the maps at http://Local.Live.com You can zoom in to various locations, add pushpins, save sets of pushpins as Collections. Aerial, Bird’s Eye and 3D view are fun too! When you sign in, your collections are visible from any
Posted by Calvin_Hsia | 3 Comments
Filed under:

Why the order of shutdown events is important

Try running this code: PUBLIC xx xx= CREATEOBJECT ("MyClass") quit && quit Foxpro DEFINE CLASS MyClass as Custom PROCEDURE init CREATE CURSOR DummyCursor ( name c(10)) && create a cursor PROCEDURE destroy SELECT DummyCursor &&
Posted by Calvin_Hsia | 4 Comments
Filed under:

Find which DLLs in your system are rebased

You can use CreateToolhelp32Snapshot and its family of functions to enumerate the running processes on your machine, including the modules loaded by each process My prior post ( DLL Image base addresses are the same in XP, different on Vista ) described
 
Page view tracker