Friday, November 20, 2009

Getting Started with Windows Azure

Here's a post on getting started building Azure applications.

Visual Studio 2010 Stuff

A couple of interesting things showed up in my feed reader today.  The are for VS 2010 and seem worth checking out.

First up is Reactive Extenstions for .NET or (Rx).  From a post on Rx:




Using Rx, programmers can write succinct declarative code to orchestrate and coordinate asynchronous and event-based programs based on familiar .NET idioms and patterns. Rx has a strong theoretical basis by using the duality between the classic Iterator and Observer design patterns to simplify controlling asynchrony. By combining the expressiveness of LINQ with the elegance of category theory, Rx allows programmers to write asynchronous code without performing cruel and unnatural acts.

As the name implies, reactive programs react to changes in their environment. Traditionally, programmers use locks and event handlers to coordinate these changes. Rx models asynchronous computations and events as push-based, or observable, collections, thus expanding the scope of the standard LINQ sequence operators and extension methods beyond the familiar pull-based, or enumerable, collections into the realm of reactive programming.

Second is TFS 2010 Power Tools.  Here's the post on that.

Wednesday, November 4, 2009

Burning CDs/DVDs on Windows Server 2008

I needed to burn some CDs using Windows Server 2008.  That OS, of course, does not have native support for burning optical media as Vista does.  My older copy of Nero (6.6) is reported to have some compatibility issues with Server 2008, so that didn't help.  Some quick Google searching turned up ImgBurn, a lightweight freeware burning utility that supports multiple file formats and all versions of Windows.  I installed it on my Windows Server 2008 box and it worked like a charm.  Recommended.

Thursday, October 15, 2009

Data Access Layers and LINQToSQL

I've been starting to do some thinking about application architecture, more specifically Data Access Layers and LINQToSQL.  Some of the things I've read, or mean to read are "LINQToSQL-The Data Access Layer Shrinker", MSDN on "Flexible Data Access With LINQ To SQL And The Entity Framework", "Creating a Data Access Layer" Part 1 and Part 2, LINQ Samples, "Build Your Own Data Access Layer" series and "Building a Multi-Tier Web Application in the .NET 3.5 Framework Using LINQToSQL".

 

Tuesday, October 13, 2009

DFSR Not Replicating *.BAK Files

I've had DFSR (DFS replication) setup for a while, but noticed that my SQL Server backups (*.BAK) files where not being replicated.  After digging into it, I found that by default, DFSR sets a file filter that excludes from replication all files that have names starting with ~ or have the extension *.tmp or *.bak.

I changed the file filter by using DFS Management Console.  Here's how:
- Go to ReplicationGroup.
- Click on the replication group.
- Go to Replicated Folder tab.
- Click on the replicated folder and there is a property page that will pop up. It will have file filter which you can change.

Thursday, October 8, 2009

LDAPS (LDAP over SSL)

Mel Keyser has a good post about configuring LDAPS.  In addition, his post contains links to some Microsoft articles and another link to a post on troubleshooting LDAPS.

Command Line Installation of SQL Server Express 2005

If you need to command line or .ini file driven installation of SQL Server Express Edition 2005, here is MSDN's article with all the details.

Here's the 'template.ini' file referenced in the above article.  It contains all of the possible configurable parameters.

; To use this .ini file, use the /settings switch on the SQL Server 2005 Setup.exe command line.
; For example: start /wait setup.exe /qb /settings c:\template.ini

; SECURITY NOTE: If you create a template.ini file that contains logins and passwords, store the file in a secured location after use.
;--------------------------------------------------------------------

; /qn is quiet mode, no GUI is displayed.
; /qb is quiet mode, basic GUI information is displayed, no user interaction is required. Use /qb for troubleshooting command line problems.

;--------------------------------------------------------------------
; The following line is REQUIRED when using a settings file.

[Options]
;--------------------------------------------------------------------
; If USERNAME or COMPANYNAME are not specified, the default operating system username and company name values for the server are used.
; Note: If names contain spaces, surround the names with quotes.

USERNAME=
COMPANYNAME=
;--------------------------------------------------------------------
; PIDKEY specifies the Product Identification Key.
; Usage: PIDKEY=ABCDE12345FGHIJ67890KLMNO  (This is not an actual key value.)

; NOTE: PIDKEY is not required for SQL Server Express Edition.
; NOTE: Do not include "-" in the PIDKEY.

;PIDKEY=
;--------------------------------------------------------------------
; INSTALLSQLDIR specifies the location for the instance specific binary files. 
; Default location is:  %ProgramFiles%\Microsoft SQL Server\
; To use the default path, do not specify the following parameter.

; NOTE: INSTALLSQLDIR is REQUIRED for clustered installations and must point to a local
; drive for which the drive letter exists on all nodes in the cluster definition.
; NOTE:  If there is a space in a specified path, surround the path with quotes
; and end every path with a '\'.

INSTALLSQLDIR=
;--------------------------------------------------------------------
; INSTALLSQLSHAREDDIR specifies a custom location for Integration Services
; Notification Services, Client Components, SQL Server Books Online and Samples.
; To use the default path, do not specify the following parameter. Default path is %ProgramFiles%\Microsoft SQL Server\

; If Tools components are already installed on the computer, this parameter is ignored.
; NOTE:  If there is a space in a specified path, surround the path with quotes
; and end every path with a '\'.

; The installation paths will be:
;\90\DTS
;\90\Notification
;\90\Tools

INSTALLSQLSHAREDDIR=
;--------------------------------------------------------------------
; INSTALLSQLDATADIR specifies the location for the SQL Server data files. 
; Default:  INSTALLSQLDIR\Data\
; To use the default path, do not specify the following parameter.

; NOTE: INSTALLSQLDATADIR is REQUIRED for clustered installations and must point to a
; shared drive which is a member of the cluster group specified for installation.
; NOTE:  If there is a space in a specified path, surround the path with quotes
; and end every path with a '\'.

INSTALLSQLDATADIR=
;--------------------------------------------------------------------
; INSTALLASDATADIR specifies the location for the Analysis Server Data Files. 
; Default:  INSTALLSQLDIR\Data\
; If Analysis Server is already installed on the computer, this parameter is ignored.
; To use the default path, do not specify the following parameter.

; NOTE:  Do not use with a SQL Server Express installation. 
; NOTE:  If there is a space in a specified path, surround the path with quotes
; and end every path with a '\'.

INSTALLASDATADIR=
;--------------------------------------------------------------------
; ADDLOCAL specifies which components to install.  If ADDLOCAL is not
; specified, setup will fail.
; To install all components specify 'ADDLOCAL=ALL' on the command line.

; ADDLOCAL Rules:
; Features are case sensitive.
; To use ADDLOCAL, provide a comma-delimited list with no spaces of the
;      features to install.

; Selecting a parent feature only installs the parent feature, not the parent and the child. 
;      For example: SQL_Engine is the parent feature, SQL_Data_Files is the child feature.
; Installing the child feature automatically installs the parent feature.
; Removing the parent feature removes the parent and all child features. See BOL for more information on this topic.

; You can also use ADDLOCAL to add components in maintenance mode. 
; -------------------------
; List of features and their ADDLOCAL properties for
; Developer, Enterprise, Evaluation, and Standard editions.
; For more information on the feature list supported per editions refer SQL Server Books Online.

; SQL Server Database Services        SQL_Engine
;    Data Files                    SQL_Data_Files
;    Replication                                    SQL_Replication
;    Full-Text Search Engine                        SQL_FullText
; Analysis Server                               Analysis_Server
;    Data Files                                     AnalysisDataFiles
; Reporting Services                             RS_Server
;    Report Manager                                 RS_Web_Interface
; Notification Services            Notification_Services
;    Engine Components                     NS_Engine
;    Client Components                NS_Client
; Integration Services                     SQL_DTS
; Client Components*                             Client_Components
;     Connectivity Components                       Connectivity
;     Management Tools                              SQL_Tools90
;     Business Intelligence Development Studio           SQL_WarehouseDevWorkbench
;     Software Development Kit                      SDK
;     SQLXML Client Features                        SQLXML
;     Legacy Components                             Tools_Legacy
; Documentation and Samples*                         SQL_Documentation
;     SQL Server Books Online                                  SQL_BooksOnline
;     Sample Databases                                          SQL_DatabaseSamples
;       AdventureWorks Sample OLTP                              SQL_AdventureWorksSamples
;       AdventureWorksDW Sample Data Warehouse             SQL_AdventureWorksDWSamples
;           AdventureWorks Sample OLAP                              SQL_AdventureWorksASSamples
;     Sample Code and Applications                          SQL_Samples 

; -------------------------
; List of features and their ADDLOCAL properties for Workgroup edition.

; SQL Server Database Services              SQL_Engine
;    Data Files                                                 SQL_Data_Files
;    Replication                                                SQL_Replication
;    Full-Text Search Engine                                    SQL_FullText
; Reporting Services                             RS_Server
;    Report Manager                                 RS_Web_Interface
; Integration Services                                      SQL_DTS
; Client Components*                                        Client_Components
;     Connectivity Components                                   Connectivity
;     Management Tools                                          SQL_Tools90
;     Software Development Kit                                  SDK
;     SQLXML Client Features                                    SQLXML
;     Legacy Components                                         Tools_Legacy
; Documentation and Samples*                       SQL_Documentation
;     SQL Server Books Online                               SQL_BooksOnline
;     Sample Databases                                          SQL_DatabaseSamples
;       AdventureWorks Sample OLTP                              SQL_AdventureWorksSamples
;       AdventureWorksDW Sample Data Warehouse             SQL_AdventureWorksDWSamples
;           AdventureWorks Sample OLAP                              SQL_AdventureWorksASSamples
;     Sample Code and Applications                          SQL_Samples 


;NOTE: (*) If setup is being performed using CD. Installing the Client Components or Documentation and Samples requires Disc 2. However, if you use the /qn switch to suppress the Setup user interface, Setup will fail to prompt for Disc 2, and return Error 70379 ("Please insert Disc 2") in the Setup log file.
; -------------------------
; List of features and their ADDLOCAL properties for Express edition.

; SQL Server Database Services        SQL_Engine
;    Data Files                                                SQL_Data_Files
;    Replication                                                SQL_Replication
; Client Components                                         Client_Components
;     Connectivity Components                              Connectivity
;     Software Development Kit                                  SDK
;--------------------------------------------------------------------
; REMOVE specifies which components to remove.

; To remove instance aware components like SQL Server, Reporting Services, Analysis Server, etc
; the REMOVE command needs to be used in conjunction with the INSTANCENAME parameter.
; For example, to remove the instance aware component AND any non-instance aware components
; like Client_Components, you would specify the following:
; REMOVE=All INSTANCENAME=MSSQLSERVER
; NOTE: Don't use if you have several instances installed and you still want to use client tools.

; To remove all non-instance aware components like Client_Components and SQL_DTS, specify
; REMOVE=ALL

; When REMOVE is specified for a new installation, components listed after
; 'REMOVE=' will NOT be included for installation.  For example to install every
; component except for Reporting Services components during a new installation specify
; the following:
; ADDLOCAL=All REMOVE=RS_Server,RS_Web_Interface

; REMOVE can be used during maintenance to remove components from an existing
; installation. For example, to remove Full-Text search specify the following:
; REMOVE=SQL_FullText

; NOTE: Removing the parent feature removes both the parent and the child feature.
; See SQL Server Books Online for more information on this topic.

ADDLOCAL=
REMOVE=
;--------------------------------------------------------------------
; INSTANCENAME is REQUIRED; for a default instance use MSSQLSERVER 
; For shared components (IS, NS and client components) INSTANCENAME is not required.

INSTANCENAME=
;--------------------------------------------------------------------
; The UPGRADE property specifies which product to upgrade.
; The allowed values are SQL_Engine, Analysis_Server, RS_Server, SQL_DTS, Notification_Services, Client_Components
; If the UPGRADE option is specified for the values (SQL_Engine, Analysis_Server, RS_Server), the INSTANCENAME parameter
; is REQUIRED to define which instance to upgrade.

; For example, to upgrade a default instance of Database Services
; use the following command line:
; UPGRADE=SQL_Engine INSTANCENAME=MSSQLSERVER

; To upgrade a named instance of SQL in which the SQL Service
; is running under a domain account, and you would like to
; add the client components and tools, run this command:
; UPGRADE=SQL_Engine INSTANCENAME=
; SQLACCOUNT=\ SQLPASSWORD=< strongpassword>
; ADDLOCAL=Client_Components


UPGRADE=
;--------------------------------------------------------------------
; The RSUPGRADEDATABASEACCOUNT and RSUPGRADEPASSWORD properties specify the Reporting Services database account and Reporting Services upgrade password respectively.

; For example to upgrade Default instance of Reporting Services and Database Services use the following command:
;/qb ADDLOCAL=All RSCONFIGURATION=Default RSSQLLOCAL=1 RSACCOUNT= RSPASSWORD= ASACCOUNT= ASPASSWORD= SQLACCOUNT=SQLPASSWORD= AGTACCOUNT= AGTPASSWORD= SQLBROWSERACCOUNT= SQLBROWSERPASSWORD= SQLBROWSERAUTOSTART=1 UPGRADE=SQL_Engine,RS_Server INSTANCENAME=MSSQLSERVER RSUPGRADEDATABASEACCOUNT=SA RSUPGRADEPASSWORD=


RSUPGRADEDATABASEACCOUNT=
RSUPGRADEPASSWORD=
;--------------------------------------------------------------------
; SKIPUPGRADEBLOCKERS switch can be used during unattended upgrade setup. To enable this switch Specify 1 and to disable do not use this switch.

; NOTE: During upgrade if this switch is used, Upgrade Blockers checks will run, however blocked results will be skipped.
; If Upgrade Blockers identifies blocked results, using this switch may result into failed setup.

;SKIPUPGRADEBLOCKERS=1
;--------------------------------------------------------------------
; SAVESYSDB can be used during uninstall to not delete system databases.
; If SAVESYSDB is set to 1 during uninstall, the system databases are left behind in the SQL data directory.

SAVESYSDB=
;--------------------------------------------------------------------
; USESYSDB specifies the root path to the data directory of the system databases during upgrade.
; For example: If the system databases were installed to "D:\Microsoft SQL Server\MSSQL.1\MSSQL\DATA", use SAVESYSDB during uninstall to save the system databases and then use USESYSDB="D:\Microsoft SQL Server\MSSQL.1\MSSQL" during installation of a new SQL Server instance to reuse the saved system databases.

USESYSDB=
;--------------------------------------------------------------------
; The services for SQL Server and Analysis Server are set auto start. To use the *ACCOUNT settings
; make sure to specify the DOMAIN, e.g. SQLACCOUNT=DOMAINNAME\ACCOUNT
; NOTE:  When installing SQL_Engine 3 accounts are REQUIRED: SQLACCOUNT, AGTACCOUNT and SQLBROWSERACCOUNT.

; SQLACCOUNT Examples:
; SQLACCOUNT=
; SQLACCOUNT="NT AUTHORITY\SYSTEM"
; SQLACCOUNT="NT AUTHORITY\NETWORK SERVICE"
; SQLACCOUNT="NT AUTHORITY\LOCAL SERVICE"


; Note: To install localized versions of SQL Server, refer to the Localized Service Names table in the SQL Server Books Online topic "Setting Up Windows Service Accounts"


; Note that if SQLBrowser is already installed, SQLBROWSERACCOUNT and SQLBROWSERPASSWORD are ignored.

SQLBROWSERACCOUNT=
SQLBROWSERPASSWORD=

SQLACCOUNT=
SQLPASSWORD=

AGTACCOUNT=
AGTPASSWORD=

ASACCOUNT=
ASPASSWORD=

RSACCOUNT=
RSPASSWORD=
;--------------------------------------------------------------------
; To use the *AUTOSTART features, specify 1 to start automatically or 0 to start manually. 
; NOTE: If you decide to start SQL Agent automatically, then SQL is also started automatically. 
; If *AUTOSTART is not specified on the command line, startup is set to manual.

SQLBROWSERAUTOSTART=0
SQLAUTOSTART=0
AGTAUTOSTART=0
ASAUTOSTART=0
RSAUTOSTART=0
;--------------------------------------------------------------------
; To use Mixed mode authentication, use SECURITYMODE=SQL.
; If SECURITYMODE=SQL is not specified, then Windows Authentication only will be used by default.
; If you use SQL Authentication, you are REQUIRED to provide a strong system administrator (SA) password.
; If you use Windows Authentication, the SA account will be disabled.
; To set SA password specify SAPWD.

SECURITYMODE=
SAPWD=
;--------------------------------------------------------------------
; SQLCOLLATION specifies the collation for Database Services.
; ASCOLLATION specifies the collation for Analysis Server.
; See SQL Server Books Online for more information on collation options.

SQLCOLLATION=
ASCOLLATION=
;--------------------------------------------------------------------
; Information for rebuilding system databases
; When system databases are corrupted, they need to be brought back to the original installed state. To rebuild the system databases set REBUILDDATABASE=1.
; This option is only available in unattended setup; either option /qb or /qn must be used

; When system databases are rebuilt it removes all database objects and data in master, model and msdb.
; In order to rebuild system databases new sa password is REQUIRED and system collation can be provided. In addition, the following parameters need to be provided: SQLACCOUNT, SQLPASSWORD, SQLAGTACCOUNT, SQLAGTPASSWORD, SQLBROWSERACCOUNT, SQLBROWSERPASSWORD

REBUILDDATABASE=
;--------------------------------------------------------------------
;REINSTALLMODE is used to repair installed components. The supported values are:
;O – Reinstall if file is missing, or an older version is present.
;M – Rewrite machine specific reg keys under HKLM
;U – Rewrite user specific reg keys under HKCU
;S – Reinstall all shortcuts

;When using REINSTALLMODE you are REQUIRED to use REINSTALL
;REINSTALL uses the same values as ADDLOCAL.
;This option is only available in unattended setup either option /qb or /qn must be used.
;For example, to repair the Management Studio shortcut in case you accidentally delete it,
;run REINSTALL=SQL_Tools90 REINSTALLMODE=S where “S” will repair only shortcuts.
; For example:
; REINSTALLMODE=S
; REINSTALLMODE=OMUS

REINSTALLMODE=
;--------------------------------------------------------------------
; RSCONFIGURATION specifies the Reporting Services installation option.

; The installation options can be either “FilesOnly” or “Default”.
; The “FilesOnly” option will only install the files without configuring the Reporting Services.
; The “Default” option will install the files and configure the Reporting Services.
; If you specify RSCONFIGURATION=Default, you must set RSSQLLOCAL=1
; NOTE: If no option is specified the default is “FilesOnly”.
; For example:
; RSCONFIGURATION=Default   
; RSCONFIGURATION=FilesOnly

RSCONFIGURATION=
;--------------------------------------------------------------------

; The RSUPGRADEDATABASEACCOUNT and RSUPGRADEPASSWORD are used for upgrading a report service.
; The account is used to connect to SQL instance that hosts RS databases. If it is not specified
; NT authenticatuion is used.

RSUPGRADEDATABASEACCOUNT=
RSUPGRADEPASSWORD=
;--------------------------------------------------------------------

; SAMPLEDATABASESERVER specifies the SQL Server instance where the sample
; databases will be attached. The parameter is used when AdventureWorks Samples or
; AdventureWorksDW Samples features are being installed.
; Sample databases need to be attached to an existing local SQL instance that is the same
; version as sample databases.
; For example: SAMPLEDATABASESERVER=\

SAMPLEDATABASESERVER=
;--------------------------------------------------------------------
; The DISABLENETWORKPROTOCOLS switch is used to disable network protocol for SQL Server instance.
; Set DISABLENETWORKPROTOCOLS = 0; for Shared Memory= On, Named Pipe= On, TCP= On
; Set DISABLENETWORKPROTOCOLS = 1; for Shared Memory= On, Named Pipe= Off (Local Only), TCP= Off
; Set DISABLENETWORKPROTOCOLS = 2; for Shared Memory= On, Named Pipe= Off (Local Only), TCP= On

; Note: DISABLENETWORKPROTOCOLS if not specified has the following defaults.
; Default value for SQL Server Express/Evaluation/Developer: DISABLENETWORKPROTOCOLS =1
; Default value for Enterprise/Standard /Workgroup: DISABLENETWORKPROTOCOLS =2

DISABLENETWORKPROTOCOLS=
;--------------------------------------------------------------------
; If you enable ERRORREPORTING, SQL Server, SQL Server Agent and Analysis Server will be configured to automatically send a report to Microsoft if a fatal error occurs.
; Microsoft uses error reports to improve SQL Server functionality, and treats all information as confidential.
; To enable error reporting specify ERRORREPORTING=1
; By default ERRORREPORTING=0

ERRORREPORTING=

;--------------------------------------------------------------------
; If you enable SQMREPORTING, SQL Server Products will be configured to automatically
; send periodic reports to Microsoft on feature usage. These reports are used to better understand
; how our customers use our products: which SQL services are installed, which features are being used,
; database deployment, use, and maintenance  patterns, etc. This will help us determine how to improve reliability and how to better target resources in ; future offerings.
; To enable error reporting specify SQMREPORTING=1;
; By default SQMREPORTING=0

SQMREPORTING=

;--------------------------------------------------------------------
; The ENABLERANU switch is used to configure Run as Normal User (User Instances).
; Set ENABLERANU = 0 to turn User Instances off.
; Set ENABLERANU = 1 (default) to turn User Instances on.
; Note: User Instances only apply to SQL Server Express SKUs.

ENABLERANU=

;--------------------------------------------------------------------
; ADMINPASSWORD parameter is used for cluster setup.
; Specify the password for the logged on user account.
; This account must be an administrator on the remote node(s).

ADMINPASSWORD=
;--------------------------------------------------------------------
; The following parameters are required for cluster installations. To run a
; cluster installation, you must be on a cluster and specify /qn or /qb in the command line.
 
; INSTALLSQLDIR - The drive letter must exist on both machines.
; INSTALLSQLDATADIR - The shared drive letter must exist in the disk group used in the GROUP parameter.
; SQLACCOUNT,SQLPASSWORD,AGTACCOUNT,AGTPASSWORD - These must all be used.
; INSTANCENAME - For a default instance use MSSQLSERVER, see BOL for instance name rules.
; SAPWD – Strong SA Password (required for SQL Authentication)
;--------------------------------------------------------------------
; REQUIRED for cluster setup - Specify the name of the virtual server.
; The name cannot exceed 15 characters and follows the same rules as for a computer name.

VS=
;--------------------------------------------------------------------
; REQUIRED for cluster setup - Specify the server that needs to be installed as a cluster
; Use SQL_Engine for SQL and Analysis_Server for Analysis Server

INSTALLVS=
;--------------------------------------------------------------------
; REQUIRED for cluster setup - Specify the IP addresses; provide one entry for each network adapter.
; NOTE: You must specify both address and network name.
; Format: IP="address,network name"
; Example: IP="xxx.xxx.xxx.xxx,Local Area Connection"

IP=
;--------------------------------------------------------------------
; REQUIRED for cluster setup - Specify the Cluster group.
; This is the group that contains the disk to which the shared data files are
; to be written, and that will contain SQL Server resources.
; Example:  GROUP="Group 2"

GROUP=
;--------------------------------------------------------------------
; REQUIRED for cluster setup - Specify which nodes you want in your Virtual Server.
; The nodes must exist in the cluster. For a new installation, the node that owns the disk group must be included in the node list.  
; Example: ADDNODE="node1,node2"


ADDNODE=
;--------------------------------------------------------------------
; Use this to remove nodes from an existing cluster (REQUIRED ONLY when performing node maintenance)

;REMOVENODE=
;--------------------------------------------------------------------

;In order to install SQL Server 2005 as a failover cluster you must create domain local groups before starting the installation.
;For each clustered service in the SQL Server instance you are installing, provide the domain name and group name.
;The groups must be specified in the format of DomainName\GroupName
;DomainName\GroupName selections must exist at the time you run SQL Server Setup.
;The account under which SQL Server Setup is running must have privileges to add accounts to the domain groups.

SQLCLUSTERGROUP=
; REQUIRED for clustered setup if SQL Engine is installed

ASCLUSTERGROUP=
; REQUIRED for clustered setup if Analysis Services is installed

AGTCLUSTERGROUP=
; REQUIRED for clustered setup if SQL Agent is installed

FTSCLUSTERGROUP=
; REQUIRED for clustered setup if Full Text Search is installed

; Example; SQLCLUSTERGROUP="MYDOMIAN\MYSQLDOMAINGROUP" AGTCLUSTERGROUP="MYDOMIAN\MYAGTDOMAINGROUP"

Tuesday, September 29, 2009

WPF Applications and the MVVM Pattern

Josh Smith has a great article on building WPF applications using the Model-View-ViewModel pattern in the February 2009 issue of MSDN magazine.

Also, Bryant Likes has post that summarizes other WPF/MVVM posts and articles.

[edit] Adding some additional links:

Josh Smith: Using a Service Locator to Work with MessageBoxes in an MVVM Application
Karl Shifflett:  M-V-VM
Dan Crevier:  List of Blog Posts
Jonn Gossman:  Tales from the Smart Client (1); Tales from the Smart Client (2)

Tuesday, September 22, 2009

.NET Assemblies

While chasing down the assembly binding error I mentioned in the previous post, I came across some useful links on .NET assemblies, covering such things as assembly binding (Fusion), changing/specifying assembly paths, strong naming, dynamically loading assemblies, native images and so on.  Richard Grimes has a tutorial here, Wikepedia has an entry on assemblies and CodeGuru has an article on strong naming.

.NET Assembly Binding Log Viewer

The other day, I was attempting to debug a VS 2008 project, but kept getting a error binding to a specific assembly (one of mine).  Despite the fact that my project had an explicit reference to version 3.x of dependent assembly (also located in the solution), Fusion (the .NET technology used to locate and load .NET assemblies) kept trying to load a previous version of the assembly.

In the course of trying to figure out the problem, I discovered the 'Assembly Binding Log Viewer' (Fuslogvw.exe), part of the Windows SDK, and found it to be highly useful in uncovering the problem.  MSDN's article on Fuslogvw is here and Neil Kilbride has a blog entry here.  For some reason which I don't yet understand, I had to set 'Log Categories' to 'Native Images' to get the info I needed.   Note that others have said the default disk log location (IE's cache) is problematic, so they recommend setting a custom log location--Click the 'Settings' button, check 'Enable Custom Log Path' and fill in 'Custom Log Path'.  You may also need to change 'Log Location' to 'Custom'.

Friday, September 11, 2009

VS 2008 Debugging Issue

Yesterday, I was using VS 2008 and attempting to debug a project by stepping code. Any attempt to step (F5, F10, etc) resulted in a dialog box telling me:

Edits were made which cannot be compiled. Execution cannot continue until the compile errors are fixed.

This problem can be fixed by turning off "Edit and Continue" in VS 2008. To do so, go to Tools->Options->Debugging->Edit and Continue. Uncheck "Enable Edit and Continue".

See also this thread.

Thursday, September 10, 2009

Exporting Hyper-V VMs to Network Shares

It is possible to export a Hyper-V VM directly to a network share, instead of having to export it locally and then copy. From Morgan Simonsen's post on Sunday, March 22, 2009 in this thread:

You can export to a network share if the user running the Hyper-V Manager on the source machine AND the source machine computer account have share AND file system permissions on the destination folder. This is also covered in the Hyper-V release notes and in Jose Barreto's Blog.

Problem solved...

Wednesday, June 10, 2009

Windows Registry Details

When dealing with Windows Vista and/or UAC, you may need to know about Registry Virtualization. According to MSDN, Registry Virtualization is "an application compatibility technology that enables registry write operations that have global impact to be redirected to per-user locations". See this post for details. Here is another article with details of how the registry works as well and COM server registration.

Building WiX

If you need to be able to build WiX, here's a great post on what is needed to do so. Also, here's a post from Rob Mensching (RobMen) on the same subject.

Monday, March 23, 2009

Current State of Solid State Disk

Here's a great article and the history of issues and current state of SSDs.

Friday, March 20, 2009

Using Sysprep on Windows Vista

Here, here and here are some links to information on using Sysprep to deploy Windows Vista.

Friday, March 13, 2009

Copying Hyper-V VMs

Here's a post about copying/duplicating Hyper-V images.

Using Sysprep on Windows XP

Here's a post on using Sysprep on Windows XP for preparing images.

Friday, March 6, 2009

Hyper-V Import Error 0x80070057

When attempting to import a set of validly exported Hyper-V virtual machines, I got the following error:

Failed to import the virtual machine from import directory 'C:\vpc\somevpc1\'. Error: One or more arguments are invalid(0x80070057)

Here's a post that solved my problem.

Thursday, January 8, 2009

Windows 2008 Server and RADIUS

If you need to configure your Windows Server 2008 installation as a RADUIS server, you'll need to add the 'Network Policy and Access Services' role. Here, here and here are some links.