VS 11 & .NET 4.5
|
|
 |

|
The shortcut key combinations listed in the Shortcut property ComboBox are the only ones available for you to use.
|
|
|
|

|
I have the following simple WinRT C++/Cx code involving inherited interface, template class and public implementation:
public interface class IFoo
{
void KungFoo();
};
public interface class IBar : IFoo
{
void Snafu();
};
template <class T>
ref class TFoo : IFoo
{
public:
virtual void KungFoo() { std::cout << "TFoo.KungFoo(" << sizeof(T) << ")" << std::endl; }
};
template <class T>
ref class TBar : TFoo<int>, IBar
{
public:
virtual void Snafu() { std::cout << "TBar.Snafu(" << sizeof(T) << ")" << std::endl; }
};
public ref class FooBar : IBar
{
private:
TBar<USHORT> bar;
public:
virtual void KungFoo() { bar.KungFoo(); }
virtual void Snafu() { bar.Snafu(); }
};
When I try to compile that I got the error:
error C3766: 'TBar<T>' must provide an implementation for the interface method 'void IFoo::KungFoo(void)'
but : TBar<T> inherit from TFoo<int> which does implement the interface!!!
What is wrong? How to fix that please?
Thanks!
My programming get away... The Blog...
Taking over the world since 1371!
|
|
|
|

|
template <class T>
ref class TBar : TFoo<int>, IBar
{
public:
virtual void KungFoo() override { TFoo<int>::KungFoo(); }
virtual void Snafu() { std::cout << "TBar.Snafu(" << sizeof(T) << ")" << std::endl; }
};
My programming get away... The Blog...
Taking over the world since 1371!
|
|
|
|

|
how to add a close click form events in form skinner
Regards
Andy
|
|
|
|

|
You need to provide considerably more detail on this if you expect a sensible answer. What language, platform, framework ... ?
One of these days I'm going to think of a really clever signature.
|
|
|
|

|
I have a C++/Cx class like so
public value struct float2
{
float x,y;
};
I'd like to add a constructor with parameter like
public value struct float2
{
float x,y;
float2(float _x, float _y);
};
and I got a compiler error. Some googling later it seems it's not possible to add a constructor to a struct.. mm... fine I guess...
Then later I was looking at
public value class Windows::Foundation::Size,
And it has a parameterized constructor!!!
Windows::Foundation::Size::Size(float w, float h)!!!
This WinRT API value class has a public constructor with parameters!! (it even implement operator overloading!)
but The best I tried I couldn't implement paremeterized constructor and operator overloading for my own value struct..
Can someone show me how to declare / implement a simple parameterized constructor (and operator overloading for '+') on my simple class above please?!!!!!!
A train station is where the train stops. A bus station is where the bus stops. On my desk, I have a work station....
_________________________________________________________
My programs never have bugs, they just develop random features.
|
|
|
|

|
Apparently Microsoft cheated...
From the same questin on MSDN forums it seems that, yes MS did that, but I can't!
Just like you can't make non sealed public ref class.
Except if you inherit from DependencyObject!
A train station is where the train stops. A bus station is where the bus stops. On my desk, I have a work station....
_________________________________________________________
My programs never have bugs, they just develop random features.
|
|
|
|

|
can anyone help me how to create a onscreen keyboard using visual c++ please..........
|
|
|
|

|
You can google on:
1. how to create a bordeless window in C++
2. how to draw in C++ with...
- GDI?
- GDI+?
- DirectX?
- Other?
take your pic!
3. How to handle mouse event
A train station is where the train stops. A bus station is where the bus stops. On my desk, I have a work station....
_________________________________________________________
My programs never have bugs, they just develop random features.
|
|
|
|

|
can you help me how to make a on screen keyboard...
|
|
|
|
 |
|
|
General
News
Suggestion
Question
Bug
Answer
Joke
Rant
Admin