conversion

How to migrate SVN with history to a new Git repository?

I read git manual, FAQ, Git - SVN crash course, etc. and they all explain this and that, but nowhere can you find a simple instruction like: SVN repository in: svn://myserver/path/to/svn/repos Git repository in: git://myserver/path/to/git/repos git-do-the-magic-svn-import-with-history svn://myserver/path/to/svn/repos git://myserver/pat...

Converting large ASP.NET VB.NET project to C# - incrementally?

Was looking for some approaches to incrementally converting an large existing ASP.NET VB.NET project to C# while still being able to deploy it as a single web application (currently deployed on a weekly basis). My thoughts were to just create a new C# ASP.NET project and slowly move pages over, but I've never attempted to do this and ...

Tabs and spaces conversion

I would like to automatically convert between tabs and spaces for indentation when I commit/update code to/from our repository. I have found the AnyEdit plugin for eclipse, which can convert directories of files. Not bad for a start, but does anybody have more expierience on how to handle this? Or maybe know of an Ant script or something...

C# VB.NET Conversion

Which tools do you use to convert between C# and VB.NET? ...

What causes java.io.CharConversionException with EOF or isHexDigit messages in Tomcat?

This exception peppers our production catalina logs on a simple 'getParameter()' call. WARNING: Parameters: Character decoding failed. Parameter skipped. java.io.CharConversionException: EOF at org.apache.tomcat.util.buf.UDecoder.convert(UDecoder.java:82) at org.apache.tomcat.util.buf.UDecoder.convert(UDecoder.java:48) at ...

Converting eps to png

What is the best way to convert a eps image to a png? Edit: The original question asked to preserve vector information, but it was pointed out that png is a raster format. The revised question therefore no longer asks for preservation of vector information. ...

PocketPC - Convert VT_DATE to an invariant VT_BSTR

I'm trying to convert a VARIANT from VT_DATE to an invariant VT_BSTR. The following code works on Windows XP: VARIANT va; ::VariantInit(&va); // set the variant to VT_DATE SYSTEMTIME st; memset(&st, 0, sizeof(SYSTEMTIME)); st.wYear = 2008; st.wMonth = 9; st.wDay = 22; st.wHour = 12; st.wMinute = 30; DATE date; SystemTimeToVariantTime...

Converting audio to code and vice-versa

Having just witnessed Sound Load technology on the Nintendo DS game Bangai-O Spritis. I was curious as to how this technology works? Does anyone have any links, documentation or sample code on implementing such a feature, that would allow the state of an application to be saved and loaded via audio? ...

Convert console exe to dll in C

I am interested in calling SoX, an open source console application, from another Windows GUI program (written in Delphi naturally). Instead of dealing with scraping and hiding the console window, I would like to just convert the application to a DLL that I can call from my application. Before I start down this path I am curious how m...

C#: Convert COMP-3 Packed Decimal to Human-Readable Value

I have a series of ASCII flat files coming in from a mainframe to be processed by a C# application. A new feed has been introduced with a Packed Decimal (COMP-3) field, which needs to be converted to a numerical value. The files are being transferred via FTP, using ASCII transfer mode. I am concerned that the binary field may contain wh...

Fastest way to convert a possibly-null-terminated ascii byte[] to a string?

I need to convert a (possibly) null terminated array of ascii bytes to a string in C# and the fastest way I've found to do it is by using my UnsafeAsciiBytesToString method shown below. This method uses the String.String(sbyte*) constructor which contains a warning in it's remarks: "The value parameter is assumed to point to an array re...

How do I parse a number from a String that may have a leading zero?

In ruby I am parsing a date in the following format: 24092008. I want to convert each section (year, month, date) into a number. I have split them up using a regex which produces three Strings which I am passing into the Integer constructor. date =~ /^([\d]{2})([\d]{2})([\d]{4})/ year = Integer($3) month = Integer($2) day = Int...

Word 97-2003 document to HTML conversion - programatically

I need to convert Word binary documents (version 97 up to 2003) into HTML documents programatically. I have googled for 3rd party libraries but most results are junk built on top of System.IO.Package which, ofcourse, are useless for other word documents except Word 2007 - Office Open XML. Do you know a good tool / library for .NET to pr...

SQL Server 2005 encryption trigger

Hello, I have a script that successfully encrypts a credit card. I need it to work as a trigger, so that any insert done to the creditcard column automatically encrypts it. Right now, my trigger works BUT the creditcard column is a varchar. When an app tries to insert, I do this: DECLARE @encryptedCreditCardNumber varbinary(max) SET @...

How can I convert List<object> to Hashtable in C#?

I have a list of objects, each containing an Id, Code and Description. I need to convert this list into a Hashtable, using Description as the key and Id as the value. This is so the Hashtable can then be serialised to JSON. Is there a way to convert from List<Object> to Hashtable without writing a loop to go through each item in the l...

Questions when moving from MbUnit to MsTest

Our team is looking to switch from using mbunit to mstest, but there appears to be some disconnect between the two. Does anyone know how to simulate the CombinatorialTest and Factory attributes from mbunit when using mstest? I think that is our only stumbling block before doing the switch. ...

How do I convert a character code back to a character?

How to I get the Fixnum returned by the following: "abc"[2] Back into a character? ...

A C# to VB.Net conversion utility that handles Automatic properties correctly?

I hope this isn't considered a duplicate since it's more pointed than similar questions (I'm curious about a specific weakness in C# to VB.net conversion utilities). I've been looking at using a tool like this .net code converter to convert a class library to VB since I'm the only one in my group comfortable with C#. The problem I've ru...

How do I convert Word smart quotes and em dashes in a string?

I have a form with a textarea. Users enter a block of text which is stored in a database. Occasionally a user will paste text from Word containing smart quotes or emdashes. Those characters appear in the database as: –, ’, “ ,†What function should I call on the input string to convert smart quotes to regular quotes and emdashes...

How do I convert a list of ascii values to a string in python?

I've got a list in a Python program that contains a series of numbers, which are themselves ASCII values. How do I convert this into a "regular" string that I can echo to the screen? ...