Guide: How to Install and Run Windows 8 and Visual Studio 2012 with Phone Emulator in Virtual Machine

יום חמישי, פברואר 21, 2013

Many developers that want to develop apps for Windows Phone 8 are required to install Windows 8 on their PCs, because Visual Studio 2012 that allows developing projects for Windows Phone 8 require this. Also, phone emulator in VS12 requires Hyper-V option that isn’t included in Windows 7. In this post I’ll explain how to avoid installing Windows 8 in order to run VS12 with phone emulator. 1. Get Windows Setup: If you don’t have your own installation of Windows 8 you can download it for free from Microsoft’s website: http://msdn.microsoft.com/en-us/evalcenter/jj554510.aspx ...

Single Instance Application Manager

יום שבת, פברואר 13, 2010

Some .Net applications are required to run as single instance process (at startup, each process “ensures” that he’s unique). This requirement may come from licensing issues, technical and/or other reasons. Quick search in Google will provide a variety of solutions, most of them are based on WindowsFormsApplicationBase object from VB.Net, usage of Mutex object and other techniques. I don’t like mixing VB with C#, and also Win-Forms solution isn’t “pure” enough for WPF applications. So I wrote my version of “Single Instance Manager”… This post will provide short description about this small project and links to download the...

Daily Tip: How to Activate Minimized Window (Form)

יום חמישי, דצמבר 24, 2009

This solution can be used in WPF and in WinForms (with some improvements). Many times UI programmer needs to activate window, the activation can be done by using “Activate()” function in window. The problem is that this function will not show window if it is minimized. In that case you can use this workaround: using System; using System.Windows;  namespace Test {        public partial class MyWindow...

“Class2Table” Exporter

יום רביעי, ספטמבר 30, 2009

“Class to Table” = “Entity to SQL” Recently, I deal with UML design in EA, also I design DB Entities for DBML (Linq2Sql). In regular way, programmer creates DB table and imports it into VS solution as entity class for DBML. But, sometimes we need to create DB table from existing class. I’m pretty sure that there are some free tools that can do this job, but as many code freaks I prefer to develop my own tools (mostly without looking for existing solutions). I want to share my community contribution at http://class2table.codeplex.com/ with small application that allows generation/creation of DB tables...

Daily Tip: How to import 3D model to WPF in couple clicks

יום ראשון, מאי 24, 2009

Import 3D Model to WPF from any 3D Editor Many 3D editors can export 3D scenes as OBJ files, these files can be easily imported into WPF project and being used to build complex 3D scenes.See how easy to import 3D scene from 3D editors (for example Blender or 3ds Max): Blender:  3ds Max:  After the export we get two files “scene_objects.obj” (contains definition of scene objects) and “scene_objects.mtl” (contains definition of objects’ materials). Now we can add these files to WPF project: Blend:Open/cerate WPF project and add OBJ and MTL files into objects’ tree.  Open target window, drag and drop added OBJ file...

Daily Tip: How to import 3D model to WPF from Blender

יום שלישי, מאי 5, 2009

In resumption to my previous post “How to import 3D model to WPF from 3D Max” I want to present the “XAML exporter for Blender” (Blender is an open-source cross-platform 3D designer). if(Blender.Name == Blend.Name) {      Debug.WriteLine(“Wiiiiii !!!! :)”); } This post will guide you how to use this feature thru simple example. Software requirements for this guide: Blender 2.48a or later, Microsoft Expression Blend 2.0 (Final Release). ...

Daily Tip: How to import 3D model to WPF from 3D Max

יום שלישי, מרץ 31, 2009

I want to present very useful feature “XAML exporter for 3D Studio Max”. This feature contains number of MAX-Script files with code that allows exporting 3D scenes from 3D Studio Max to XAML files. “Max2Xaml” Project on Codeplex website: http://max2xaml.codeplex.com. I’ll try to present a simple guide for this feature with some useful example. Software requirements for this guide: 3D Studio Max 2007 or later (I use 3D Studio Max 2009), Microsoft Expression Blend 2.0 (Final Release). SDK and Framework requirements: Microsoft .Net...

Quick Tip: How to work with Excel files in VB.Net

יום שלישי, יולי 8, 2008

Recently I've being asked by friend to show him a simple way to read/write data from/to MS Excel files. I found my old project with very simple method of working with excel files by using Microsoft.Jet.OLEDB.4.0 Provider (similar to MS Access). This is one of many methods to work with excel files. Read data from Excel Sheet:     ''' <summary>     ''' Reads the data from excel file.     ''' </summary>     ''' <param name="strFilePath">The file path.</param>     ''' <param name="strSheetName">Name of the sheet.</param>     ''' <returns></returns>     Public Function ReadDataFromExcelFile(ByVal...

Build multi-touch display in 10 minutes!

יום שני, מאי 5, 2008

Always wanted personal multi-touch cool display? - You don't need to buy any expensive hardware, just this... Great project from NUI-Group. So, what do we need to get this work? 1. Software: download ZIP file from here and extract in any folder on your hard disk (see minimum requirements before the installation). 2. Simple box (30cm x 30cm x 30cm). 3. Webcam . 4. Transparent surface (can be glass, fiberglass or disassemble your picture frame). 5. White paper (A4). 6. Build the "device" according to instruction on this video. 7. Connect your webcam to USB and make it working (you're a big guy,...

How to run WPF-XBAP Application in Full-Trust Mode (Post #2: certificate extraction)

יום שני, מרץ 31, 2008

In previous post I wrote about running WPF-XBAP application on client machine in "Full-Trust Mode". That worked fine and the post was helpful (I know this from post's talk-backs). I described how to generate security certificate and how to install it on client machine (thru IE options). Recently, I worked with XBAP deployment files and required to copy them to new IIS server, during the process I've forgotten to include certificate (ext: "cer") file. I tried to open the application from client machine (in IE or Firefox) and got error message, that tells about security restrictions and that client has refused...