Friday, 21 October 2011

How to import existing code to svn with visualsvn and tortoisesvn

You might have some code which is not under version control, and it is mixed with binaries or other files that you don't really want in the svn repository. If the code in question contains both files that should be and should not be versioned, the easiest way to do it is this:

1. In visualsvn create a new repository, with the name of the project you want to version, let's say the new repository name is MyProject

2. Rename the folder containing the source code you want to version, let's say is called MyProject, we rename it to MyProject-

3. Create a new folder with the same name as the one you just renamed: MyProject

4. Using tortoise svn do an svn checkout from repository MyProject into the new empty folder MyProject you have just created

5. Move all the files from the renamed folder MyProject- into the new folder MyProject

6. Using tortoise svn do an "add" operation on the new folder MyProject, and choose the files you want to include in svn (probably you will avoid the binaries, object files and other stuff that you don't want versioned)

7. Using tortoise svn do a commit of the newly added files/folders into svn repository

8. Delete the renamed folder MyProject- as it is not needed any more

Monday, 30 May 2011

Monday, 28 September 2009

VB .NET Converter

First, worth to try the VS built in converter.

Another one that looks good, worth a try http://www.aivosto.com/project/vbnet.html - says it works with previous versions and there is trial for small projects.

Microsoft Visual Basic 6.0 Code Advisor can be used on VB6 before converting to VB.NET:
http://msdn.microsoft.com/en-us/vbasic/ms789135.aspx

Finally a couple of more:

http://www.vbto.net/

http://www.vbmigration.com/editions.aspx

Other useful links for migration of VB6 to .NET

http://blogs.msdn.com/ericnel/archive/2008/04/25/visual-basic-6-migration-to-net.aspx
http://msdn.microsoft.com/en-gb/vbrun/ms788233.aspx
http://msdn.microsoft.com/en-gb/dd408373.aspx

Finally here is a promissing link for 5 to 6 but can't follow it at the moment: http://www.topblogarea.com/sitedetails_17682-2.html

Thursday, 24 September 2009

how to get the default schema for a user in MSSQL 2005

execute the stored procedure sp_helpuser, for example


sp_helpuser 'domainname\username'

One of the resulting columns is DefSchemaName.

There is a similar proc sp_helpgroup to show the users in a group but does not include schema information.

Another way to get the schema information is

select name, default_schema_namefrom sys.database_principals uwhere u.name='username'