A
Adriano Coser
I'm getting the following error:
error C3767: PictureSource - candidate function(s) not accessible
when accessing a public member function of a managed class, either
from managed or unmanaged code. The class is an owner draw control
implemented into a Control Library. The access is on a DLLs that
support CLR with old syntax.
The code compiled OK on Beta-1.
Bellow is the hearder file for the accessed class. The error occours
accessing PictureSource function. TPictureSource is an unmanaged
class, but I don't think that could be the problem.
Does anyone have a clue?
Thanks in advance for any help.
Regards,
Adriano.
#pragma once
#include "PictureSource.h"
using namespace System;
using namespace System::ComponentModel;
using namespace System::Collections;
using namespace System:iagnostics;
using namespace System:rawing;
namespace QiVControls
{
/// <summary>
/// Summary for PictureListBox
/// </summary>
[ToolboxBitmap(__typeof(Windows::Forms::ListBox))]
__gc public class PictureListBox : public Windows::Forms::ListBox
{
public:
PictureListBox(void)
{
InitializeComponent();
InitializeWindow();
}
PictureListBox(System::ComponentModel::IContainer *container) :
components(0)
{
/// <summary>
/// Required for Windows.Forms Class Composition Designer support
/// </summary>
container->Add(this);
InitializeComponent();
InitializeWindow();
}
TPictureSource* PictureSource();
void PictureSource(TPictureSource* _pictureSource);
protected:
void Dispose(Boolean disposing)
{
if (disposing && components)
{
components->Dispose();
}
__super:ispose(disposing);
}
private:
/// <summary>
/// Required designer variable.
/// </summary>
System::ComponentModel::Container *components;
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
void InitializeComponent(void)
{
//
// PictureListBox
//
this->DrawMode = System::Windows::Forms:rawMode::OwnerDrawFixed;
this->DrawItem += new
System::Windows::Forms:rawItemEventHandler(this,
&PictureListBox:rawItemPictureListBox);
}
TPictureSource* pictureSource;
private:
System::Void DrawItemPictureListBox(
System::Object * sender,
System::Windows::Forms:rawItemEventArgs * e);
void InitializeWindow();
};
}
error C3767: PictureSource - candidate function(s) not accessible
when accessing a public member function of a managed class, either
from managed or unmanaged code. The class is an owner draw control
implemented into a Control Library. The access is on a DLLs that
support CLR with old syntax.
The code compiled OK on Beta-1.
Bellow is the hearder file for the accessed class. The error occours
accessing PictureSource function. TPictureSource is an unmanaged
class, but I don't think that could be the problem.
Does anyone have a clue?
Thanks in advance for any help.
Regards,
Adriano.
#pragma once
#include "PictureSource.h"
using namespace System;
using namespace System::ComponentModel;
using namespace System::Collections;
using namespace System:iagnostics;
using namespace System:rawing;
namespace QiVControls
{
/// <summary>
/// Summary for PictureListBox
/// </summary>
[ToolboxBitmap(__typeof(Windows::Forms::ListBox))]
__gc public class PictureListBox : public Windows::Forms::ListBox
{
public:
PictureListBox(void)
{
InitializeComponent();
InitializeWindow();
}
PictureListBox(System::ComponentModel::IContainer *container) :
components(0)
{
/// <summary>
/// Required for Windows.Forms Class Composition Designer support
/// </summary>
container->Add(this);
InitializeComponent();
InitializeWindow();
}
TPictureSource* PictureSource();
void PictureSource(TPictureSource* _pictureSource);
protected:
void Dispose(Boolean disposing)
{
if (disposing && components)
{
components->Dispose();
}
__super:ispose(disposing);
}
private:
/// <summary>
/// Required designer variable.
/// </summary>
System::ComponentModel::Container *components;
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
void InitializeComponent(void)
{
//
// PictureListBox
//
this->DrawMode = System::Windows::Forms:rawMode::OwnerDrawFixed;
this->DrawItem += new
System::Windows::Forms:rawItemEventHandler(this,
&PictureListBox:rawItemPictureListBox);
}
TPictureSource* pictureSource;
private:
System::Void DrawItemPictureListBox(
System::Object * sender,
System::Windows::Forms:rawItemEventArgs * e);
void InitializeWindow();
};
}