|
You mean that's not in the posting guidelines yet?
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
LMAO, Glad I didn't have a mouth full of coffee when I read that!
led mike
|
|
|
|
|
Hi All,
How does one export a function (not a class) in a managed Dll?
I'm catching a System.EntryPointNotFoundException. dumpbin confirms that the Dll is not exporting the function.
Does not work:
* declaring method as public: error C2059: syntax error : 'public'
* __declspec( dllexport ): incompatible with /clr and /clr:pur
* .def file: fatal link error LNK1310: Exports not supported for pure MSIL image
Thanks,
Jeff
bool Test( array<byte>^ );
bool Test( array<byte>^ a ) {...}
|
|
|
|
|
Wrapping in a public class is one option:
public ref class StaticFuncs
{
public:
static bool Test( array<byte>^ a )
{
...
}
};
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Hi,
i want to write a MDI application with 3 child windows. The left and right ones are fixed tool windows. The middle one should be moveable and sizeable between these other to child windows.
But if the user would maximize the middle Window it would maximize the the hole client area.
I tried something like that:
System::Drawing::Size szMax;
szMax.Width = 500;
szMax.Height = 300;
_middleChildWindow_->MaximumSize = szMax;
Rectangle boundRect(100, 10, 200, 200);
vcHG->MaximizedBounds = boundRect;
but I get following error
error C3767: "System::Windows::Forms::Form::MaximizedBounds::set": Auf mögliche Funktion(en) kann nicht zugegriffen werden.
(means the function cant be accessed)
Why is that? The function is protected so I should be able to access it.
I also don´t know how to prevent the user from moving the middle window over the other child windows.
I would appreciate any help
Thanks
|
|
|
|
|
Kyon86 wrote: vcHG->MaximizedBounds = boundRect;
but I get following error
error C3767: "System::Windows::Forms::Form::MaximizedBounds::set": Auf mögliche Funktion(en) kann nicht zugegriffen werden.
(means the function cant be accessed)
I have no idea what type vcHG is but the following code compiles for me in VS2005 where this is a System::Windows::Forms::Form
System::Drawing::Rectangle rect(10,10,10,10);
this->MaximizedBounds = rect;
led mike
|
|
|
|
|
I want to have registry access in limited user account in windows xp.
Could any one please help me
Thanks
Gayatri S
|
|
|
|
|
Run regedit.exe as an Administrator from within the limited user account.
Regards,
--Perspx
"The Blue Screen of Death, also known as The Blue Screen of Doom, the "Blue Screen of Fun", "Phatul Exception: The WRECKening" and "Windows Vista", is a multi award-winning game first developed in 1995 by Microsoft" - Uncyclopedia
|
|
|
|
|
First off you are in the wrong forum. None of your questions are about managed or mixed mode development which this forum is intended for as one might see if they READ the first message in the forum.
Second, one interpretation of your collection of posts is that you believe the way to learn about subjects is to ask people in internet forums to teach them to you. In my opinion this about the worst way to attempt learning a subject. A more efficient method would be to read the documentation or even buy a book that covers the subject. Also there is a mountain of articles and blog entries on the internet that might provide introductory type explanations of subject. One can happily find them by using Google to search for them. There are actually a lot of these articles on CodeProject, the CodeProject articles are a primary purpose of this site. Look through the "CHAPTERS" menu on the site. Then once you have at least a beginner level grasp of the subject people in forums might be able to help you with specific problems if/when you get stuck on something.
led mike
|
|
|
|
|
Well put
Regards,
--Perspx
"The Blue Screen of Death, also known as The Blue Screen of Doom, the "Blue Screen of Fun", "Phatul Exception: The WRECKening" and "Windows Vista", is a multi award-winning game first developed in 1995 by Microsoft" - Uncyclopedia
|
|
|
|
|
Let me answer your question one by one:
I dont think all my questions are irrerevelant to the group.
Secondly thanks a lot for your interpretation that i ask people questions and learn .If my intention is that then i would join some classes rather that posting questions in the forum .
I can buy books thats again a good thought but let me make it clear to you that had i not read any books then i would not even be coding , or rather my questions are not soo preliminary
and thirdly searching on the google , i have been searching for these questions but when i could not find appropriate ans i ask questions here
Please for gods sake help people but do not tell them what to do.
You could have put the same thing in a better way or rather you could have directed me to the correct group which you haven't this clearly shows that you like to rebuke ppl,
its always easy to point mistakes but difficult to help others.
|
|
|
|
|
gayatri.neelema wrote: Please for gods sake help people but do not tell them what to do.
Look, you've been a member of this site for 6 months. I know what's going on here far better than you do. I suggest that you listen to me rather than argue with me. You have posted this question IN THE WRONG FORUM, period. Figure it out or get lost, either way I don't care.
led mike
|
|
|
|
|
I have not argued with you but asked u to be more sensible and help ppl.
may be you have more experience but u dont have to any right to be rude you could have been better but u r getting worse fine i understand that its ur problem and i am not even interested in what or who u r ,
i better chose to ignore u and not care for any of ur messages
|
|
|
|
|
|
Geeze, long enough post? It's best just to post only your trouble spot.
math415 wrote: If your program won't at least compile and run (even if it gives incorrect answers) you'll lose 10 points.
Homework problem. You should really be consulting with your instructor.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Hi ,
I want to write a sample application for registry cleaning.
I wanted to know how do we decide if a particular registry key is invaid or not so that we can delete the key.
How do we search for invalid registry keys.
I am using c++
Thanks,
Gayatri
|
|
|
|
|
The keys under HKEY_CLASSES_ROOT are pretty well defined - you can
cleanup orphaned file/type associations relatively easily.
Beyond that I'm not sure how much you can reliably do. There's no magic
APIs that will tell you if an item in the registry is still being used.
I do know you can make your system unusable very easily
Good luck!
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanks for you answer.
It would be nice of you if you cold tell me how will is the relation mainitained for the keys which are being used .
I am novice to it,so it would be great if you could explain it with an example.
Thanks
|
|
|
|
|
|
Hi,
I want to find the active threads running in a process.
I am using c++ and win32 API's.
Thanks,
Gayatri
|
|
|
|
|
If this isn't a Managed C++ question (using .NET) please direct your question to C++ Forum[^]. If you are using the managed libraries, you can use the System.Diagnostics.Process[^] class to get the Threads[^] that belong to that process.
|
|
|
|
|
You could use the WMI Win32_Process and Win32_Thread classes.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I need to call a managed C++ dll from our native C++ code. To manage this i followed the tutorial in http://support.microsoft.com/kb/828736 "How to call a managed DLL from native Visual C++ code in Visual Studio.NET or in Visual Studio 2005."
However I'm using VS2008 and the article is using a managed C# dll.
Were the article says:
Replace the following lines of code in the AssemblyInfo.cs file
[assembly: ComVisible(false)]
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("")]
with the following.
[assembly: ComVisible(true)]
[assembly: AssemblyDelaySign(false)]
[assembly: AssemblyKeyFile("..\\..\\MyKeyFile.SNK")]
I added the SNK file to the projects property "linker->Advanced->Key File" and changed [assembly: ComVisible(false)] in the AssemblyInfo.cpp file.
Now when I build my solution I get following errors in the native code:
error C2787: 'WNXal::NeXus' : no GUID has been associated with this object
error C2079: 'pINeXus' uses undefined struct 'WNXal::INeXus'
Code snippit:
--------------
#import "../Lib/NeXus/References/WNXal.tlb" raw_interfaces_only
using namespace WNXal;
HRESULT hr = CoInitialize(NULL);
INeXus pINeXus(__uuidof(WNXal::NeXus));
long lResult = 0;
e = pINeXus->Initialize();
CoUninitialize();
Benny
|
|
|
|
|
Stray Bullet wrote: I need to call a managed C++ dll from our native C++ code.
Alternatively you can make a mixed mode project to solve that problem without the need to expose the managed classes using COM
[Native module] calls --> [Mixed Mode module] calls --> [Managed module]
no COM.
led mike
|
|
|
|
|
I have designed a Winform Form, lets say Form1.h. I can switch to its Form designer and drop components etc. Now, if i insert this Form1.h in a different solution/project, i can compile, call the Form, but i cannot switch to the form designer. It's like a plain .h file. How can i make VS2008 understand that this is a form, so that i can edit it visually?
I'm using VS2008 C++/CLR.
Thanks
|
|
|
|