Programming & Development

  • Convert VDI to VMDK with VBoxManage

    Cloning virtual HDs First, make sure you have enough HD space to store both hard drive (images) so you can maintain original in case of failure/conversion corruption/power outage during conversion etc. If this is on an external HD or remote… Continue reading

  • Keep Batch File Open to enter more commands

    Typically the solution you will see to this question upon googling is to add “pause” to the end of your batch file. This will keep the batch open, but it will not allow you to enter additional commands and after… Continue reading

  • .NET Map Drive in C# (WPF)

    Complete class reference updated for WPF (not yet tested). For backwards compatibility, previous Win32 code maintained in code comments (and just replace ‘Window’ with ‘Form’). References StackOverflow (blog), http://stackoverflow.com/questions/3465182/how-to-map-a-drive-using-c PINVOKE (code references and snippets), http://pinvoke.net/default.aspx/Structures/NETRESOURCE.html MSDN (info on class types… Continue reading

  • WPF Quick Reference

    get window handle bring to front common resource dictionaries for skinning (this blog) References wpf get window handle (stackoverflow) http://stackoverflow.com/questions/1556182/finding-the-handle-to-a-wpf-window wpf bring to front (stackoverflow) http://stackoverflow.com/questions/257587/bring-a-window-to-the-front-in-wpf Continue reading

  • Common WPF Resource Dictionaries

    Skinning a WPF application is as simple as adding an assembly reference (PresentationFramework.Aero) and xml config change. See below. Other sources: References StackOverflow, http://stackoverflow.com/questions/2075720/windows-7-theme-for-wpf Continue reading

  • Create Custom and Self Signed SSL Certificate in IIS 6 (Windows Server 2003)

    Single domain Ex. http://www.ronniediaz.com Note: Foremost, in order to access your site over HTTPS, the HTTP SSL Service will need to be running. This service binds to port 443 and filters HTTP traffic to IIS. Relatively easy to do in… Continue reading

  • Arithmetic overflow error converting type to data type numeric

    This error usually occurs when the type you are trying to convert to a decimal or numeric is larger than the column or casted type you are converting to. Ex. Since the number specifed is 7 digits long include after… Continue reading

  • Serialize C# object to JSON JavaScriptSerializer .Net

    References MS Blogs, http://blogs.microsoft.co.il/blogs/pini_dayan/archive/2009/03/12/convert-objects-to-json-in-c-using-javascriptserializer.aspx JSON.org, http://www.json.org/js.html C# Cross-Site Page Access, http://stackoverflow.com/questions/6290053/setting-access-control-allow-origin-in-asp-net-mvc-simplest-possible-method PHP Cross-Site Page Access, http://rayfd.wordpress.com/2007/03/28/why-wont-eval-eval-my-json-or-json-object-object-literal/ JS Eval string to JSON Object, http://rayfd.wordpress.com/2007/03/28/why-wont-eval-eval-my-json-or-json-object-object-literal/ Continue reading

  • DLL in Stored Procedure MSSQL

    Extended Stored Procedures (MSDN), http://support.microsoft.com/kb/190987 Thread Local Storage in an extended stored procedure (MSDN), http://support.microsoft.com/kb/163449 Continue reading

  • WCF Service Library in Windows Service

    References CodeProject (WCF Service in Windows Service), http://www.codeproject.com/KB/WCF/WCF_windows_hosting.aspx MSDN (Debug Windows Service Applications), http://msdn.microsoft.com/en-us/library/7a50syb3(v=vs.80).aspx MSDN (Host WCF Service in Managed Windows Service), http://msdn.microsoft.com/en-us/library/ms733069.aspx Continue reading