Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Managed C++/CLI
  4. Odd Error....

Odd Error....

Scheduled Pinned Locked Moved Managed C++/CLI
c++databasesysadminxmlhelp
4 Posts 2 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    Nick Parker
    wrote on last edited by
    #1

    Aren't they all. Ok, actully I am not sure as to why I am getting this, or even what it really means. I am simply writing a MC++ assembly that does some data access. There error points to this line here:

    mySQLConnection = new SqlConnection(S"server=local;Trusted_Connection=yes;database=DeveloperNotes;");

    However I have this declared above it:

    SqlConnection * mySQLConnection;

    I have included the following:

    #using <mscorlib.dll>
    #using <system.data.dll>
    #using <System.Xml.dll>

    using namespace System;
    using namespace System::Data;
    using namespace System::Data::SqlClient;
    using namespace System::Xml;

    Does anyone have any ideas about this error? :confused: c:\Documents and Settings\User\Desktop\new_article\mcpp\mcpp.cpp(18): error C3624: 'System::ComponentModel::Component': the compiler cannot find this type; it is defined in the assembly 'System' Nick Parker
    May your glass be ever full. May the roof over your head be always strong. And may you be in heaven half an hour before the devil knows you’re dead. - Irish Blessing


    N 1 Reply Last reply
    0
    • N Nick Parker

      Aren't they all. Ok, actully I am not sure as to why I am getting this, or even what it really means. I am simply writing a MC++ assembly that does some data access. There error points to this line here:

      mySQLConnection = new SqlConnection(S"server=local;Trusted_Connection=yes;database=DeveloperNotes;");

      However I have this declared above it:

      SqlConnection * mySQLConnection;

      I have included the following:

      #using <mscorlib.dll>
      #using <system.data.dll>
      #using <System.Xml.dll>

      using namespace System;
      using namespace System::Data;
      using namespace System::Data::SqlClient;
      using namespace System::Xml;

      Does anyone have any ideas about this error? :confused: c:\Documents and Settings\User\Desktop\new_article\mcpp\mcpp.cpp(18): error C3624: 'System::ComponentModel::Component': the compiler cannot find this type; it is defined in the assembly 'System' Nick Parker
      May your glass be ever full. May the roof over your head be always strong. And may you be in heaven half an hour before the devil knows you’re dead. - Irish Blessing


      N Offline
      N Offline
      Nick Parker
      wrote on last edited by
      #2

      Geez, I decided to walk away and came back to my computer 2 hours later, looked at my screen and realized that I was missing this statement:

      #using <System.dll>

      All Fixed. :) Nick Parker
      May your glass be ever full. May the roof over your head be always strong. And may you be in heaven half an hour before the devil knows you’re dead. - Irish Blessing


      N 1 Reply Last reply
      0
      • N Nick Parker

        Geez, I decided to walk away and came back to my computer 2 hours later, looked at my screen and realized that I was missing this statement:

        #using <System.dll>

        All Fixed. :) Nick Parker
        May your glass be ever full. May the roof over your head be always strong. And may you be in heaven half an hour before the devil knows you’re dead. - Irish Blessing


        N Offline
        N Offline
        Nick Hodapp
        wrote on last edited by
        #3

        It's because SqlConnection is derived from Component, and the types reside in different assemblies. Nick This posting is provided “AS IS” with no warranties, and confers no rights. You assume all risk for your use. © 2002 Microsoft Corporation. All rights reserved.

        N 1 Reply Last reply
        0
        • N Nick Hodapp

          It's because SqlConnection is derived from Component, and the types reside in different assemblies. Nick This posting is provided “AS IS” with no warranties, and confers no rights. You assume all risk for your use. © 2002 Microsoft Corporation. All rights reserved.

          N Offline
          N Offline
          Nick Parker
          wrote on last edited by
          #4

          Nick, First off thanks, I don't want to bug you however it doesn't seem like this forum gets as much attention as some of the others. Could you take a look at thread I posted above: http://www.codeproject.com/script/comments/forums.asp?msg=346059&forumid=3785#xx346059xx[^]. I have no idea why I am getting 0 back all the time. This code, once it works will be a class written in MC++ and instantiated in C# as a web service. I hadn't seen anything like it yet so I thought it would be interesting to try. Thanks. :) Nick Parker
          May your glass be ever full. May the roof over your head be always strong. And may you be in heaven half an hour before the devil knows you’re dead. - Irish Blessing


          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups