CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 10 of 10

Threaded View

  1. #1
    Join Date
    Apr 2011
    Posts
    6

    Vs6 to VS2008 Template Problem

    Hi

    I'm in the midst of porting an old VS6 project to VS2008/2010 and have hit a compilation problem associated with a template class. I would appreciate any comments or suggestions on reaching a resolution to the problem!

    Regards

    Rch83199

    The error is as follows :-

    1>DicomDataElement.cpp
    1>c:\development\pacs\pacs\pacs\dicomdataelement.cpp(478) : error C2664: 'CStringDicomDataValue::Set' : cannot convert parameter 1 from 'CSingleDataElement<T>:ata_type' to 'const char *'
    1> with
    1> [
    1> T=const char *
    1> ]
    1> Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
    1> c:\development\pacs\pacs\pacs\dicomdataelement.cpp(465) : while compiling class template member function 'bool CSingleDataElement<T>::Add(const CSingleDataElement<T>:ata_type &)'
    1> with
    1> [
    1> T=CAgeStringDicomData
    1> ]
    1> c:\development\pacs\pacs\pacs\dicomdataelement.cpp(38) : see reference to class template instantiation 'CSingleDataElement<T>' being compiled
    1> with
    1> [
    1> T=CAgeStringDicomData
    1> ]
    Last edited by rch83199; April 6th, 2011 at 03:25 PM. Reason: change attachment

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured