Unable to resolve type 'RedGate.SQLCompare.Engine.Database

JohnJohn Posts: 3
edited June 26, 2006 10:06AM in SQL Toolkit Previous Versions
Using Visual Studio 2005, going through the tutorial "Automating SQL Compare". I saw a posting in the forum from 2004 with the same error when VS2005 was still in beta. Is this fixed now?

I've referenced: RedGate.SQL.Shared
RedGate.SQLCompare.Engine

I've created the licenses.licx file which contains:
RedGate.SQLCompare.Engine.Database

I need to know what I'm doing wrong, or a workaround please, STAT! :(

Thanks!

Comments

  • Hi John,
    Have you built the SQL Compare Code snippits example under VS2005?
    As you have specified, you need to

    Add references to RedGate.SQL.Shared, RedGate.SQLCompare.Engine

    Add the following lines to the top of your C# class
    using RedGate.SQL.Shared;
    using RedGate.SQLCompare.Engine;
    
    or VB.NET code
    Imports RedGate.SQL.Shared
    Imports RedGate.SQLCompare.Engine
    

    Setup the licenses.licx file (as an embedded resource) to contain the following line
    RedGate.SQLCompare.Engine.Database, RedGate.SQLCompare.Engine

    You may need to rebuild your project. (Especially if you have a trial license and then later purchase your SQL Compare Professional license). You can rebuild your application in VS2005 by right clicking on your project in solution explorer and select Rebuild.
    [/list]
  • Awesome - thanks for your help. What worked for the record, was doing as follows in licenses.licx:

    RedGate.SQLCompare.Engine.Database, RedGate.SQLCompare.Engine

    It seems obvious in hindsight, but I'm a computer geek, so I tend to follow instructions literally. The tutorial just said to put:

    RedGate.SQLCompare.Engine.Database

    in the licenses.licx file. I'll be able to stop my boss breathing down my neck now. Thanks again!
Sign In or Register to comment.