15,885,128 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View Python questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by ARopo (Top 60 by date)
ARopo
5-Oct-15 6:32am
View
I never did get to the bottom of this, ended up loading the class library dynamically and using reflection to call it. I think in may be something to do with dll initialization and the timing and order of things.
ARopo
23-Jul-12 11:35am
View
what is it you are trying to access from vb6? the solution in this post is for hosting a .net user control on a vb6 form.
Sounds like either your manifest is not embedded or is not correct - use mt.exe to extract and check the manifest from your .net dll. Also try using sxstrace to diagnose the problem. You also need a manifest for the VB6 exe that refers to the .net dlls as dependencies.
ARopo
10-May-12 6:36am
View
Solution 3 could indeed be the case, there are many reasons why debug and release can give different outcomes, I've certainly been tripped up by putting vital code into an assert macro.
ARopo
19-Dec-11 5:54am
View
Can't see any reason for this in the code provied , where is m the error refers to parameter m
ARopo
12-Sep-11 9:09am
View
Thanks, I did have binary compatability on, but still got new guids. However your answer led me to look at it in more detail and I discovered that the binary compatable dll referrenced had a different type lib version to the dll I was buildinf and hense generated new guids. I updated the dll reference and hey presto consistant guids.
ARopo
12-Sep-11 9:09am
View
Thanks, I did have binary compatability on, but still got new guids. However your answer led me to look at it in more detail and I discovered that the binary compatable dll referrenced had a different type lib version to the dll I was buildinf and hense generated new guids. I updated the dll reference and hey presto consistant guids.
ARopo
12-Sep-11 8:52am
View
Deleted
Thanks for the response, but I already hace it set to binary compatibility and it still has new guids each time. I just double checked.
ARopo
12-Sep-11 8:52am
View
Deleted
Thanks for the response, but I already hace it set to binary compatibility and it still has new guids each time. I just double checked.
ARopo
3-Aug-11 4:51am
View
That is pretty much what we do
ARopo
29-Jul-11 5:36am
View
I think as you say using AppDomains is the answer, but I'm have difficultly understanding how to set one up, it look as though if I load a dll to a new application domain as in my example it loads the dll to both the new domain and the current domain maybe I need to create a domain and somehow load my dlls from within it.
ARopo
29-Jul-11 5:28am
View
I think Most of the memory added is the actual size of the dll I'm loading along with all its dependancies. It is not leaking in that it does reach a maximum but since my application is run from a shared server terminal service I need to free up this memory when I'm finised with it.
ARopo
29-Jul-11 5:21am
View
I have c#.Net dll that is available through COM This .Net dll then Loads .net DLLs as shown in the loading code in my question. Problem is that when I unload the application domain it has little of no effect. I Suspect that it is not quite as simple as I first thought.
ARopo
7-Jul-11 4:37am
View
I gave you 5 for the answer, but didn't acccept it because the question was how can I do this in win32 without access to .net. I already knew how to do it the way you suggested.
ARopo
5-Jul-11 7:26am
View
It only would have been quicker if an api call existed to do this. But since it doesn't then it is not a solution. For now I've avoided the problem by using sn to get the keys the put the keys in a file which I read from the win32 console application.
ARopo
5-Jul-11 7:21am
View
not off the top of my head, any info on that would be useful I think I might revisit this at a later date, thanks
ARopo
5-Jul-11 5:58am
View
Another dirty solution I considered would be to call sn -T from my win32 application and extract the output. It does appear as though a win32 api call for this doesn't exist.
ARopo
5-Jul-11 5:45am
View
Some background to this: We have a product which is a mix of win32 binaries and .net assembles. Many of the win32 modules use COM. Some .net modules are called through COM, and call some win32 modules through COM. Problem is we don't want a COM/Registry dependancy for deployment reasons, so we have to generate sidebyside manifest files and run the application COM free. We have 2 tools that generate the manifests Regsvr42 (win32 C++ console app) and GenMan (.net and deals with .net assemblies) The main exe is a win32 application so we use Regsvr42 to generate this manifest. In this generated manifest are listed all the dependancies of the exe some of which are strong named .net assemblies. Thus my question, regsvr42 is a win 32 console application written in C++ and compiled with /mt (so is incompatable with /clr i.e. cannot access .net)
ARopo
5-Jul-11 5:45am
View
Avoid using .NET in this instance I was looking for a quick solution that could be used with my application's existing win32 /MT environment. Otherwise I would have just converted the application to use /clr and access .net. See earlier comments for the background and ultimate goal.
ARopo
5-Jul-11 5:45am
View
Deleted
Avoid using .NET in this instance I was looking for a quick solution that could be used with my application's existing win32 /MT environment. Otherwise I would have just converted the application to use /clr and access .net. See earlier comments for the background and ultimate goal.
ARopo
5-Jul-11 5:11am
View
Thank for taking the time to answer but this was exactly the sort of thing I wanted to avoid, due to time constrants. I think you could do something simpler by re-writing regsvr42 as a c++/.net console application but I don't have time for that either. My current solution involves reading a list of public key tokens from a file - not great but quick. I gave the example of GetFileVersionInfo as an example of the kind of api call I'm looking for only it might be called GetPublicKeyToken if it existed point is it would be win32 API not .net
ARopo
5-Jul-11 5:04am
View
Deleted
Some background to this: We have a product which is a mix of win32 binaries and .net assembles. Many of the win32 modules use COM. Some .net modules are called through COM, and call some win32 modules through COM.
Problem is we don't want a COM/Registry dependancy for deployment reasons, so we have to generate sidebyside manifest files and run the application COM free.
We have 2 tools that generate the manifests Regsvr42 (win32 C++ console app) and GenMan (.net and deals with .net assemblies)
The main exe is a win32 application so we use Regsvr42 to generate this manifest. In this generated manifest are listed all the dependancies of the exe some of which are strong named .net assemblies. Thus my question, regsvr42 is a win 32 console application written in C++ and compiled with /mt (so is incompatable with /clr i.e. cannot access .net)
ARopo
14-Mar-11 6:14am
View
Not clear what you want to acheive here. Do you want a modal or modeless dialog, why do you want to run a modal dialog on a separate thread?
ARopo
4-Mar-11 3:58am
View
I wouldn't be using ActiveX or VB6 code if I could help it. Unfortunatitly I can't make a business case for spending a year or 2 porting everything to .net. So we take a steady migration approach and make the best of what we have.
ARopo
3-Mar-11 8:09am
View
This is correct only on the development machine. Problem we have with this is that we may be working on more than one version at a time so building updates the registry to the last version built.
ARopo
28-Jan-11 6:33am
View
Oh year, thanks for the code you learn something everyday. +5 for the comment
ARopo
28-Jan-11 5:26am
View
Deleted
Reflection is designed to tell you what is already in a class at runtime not to add things to it.
ARopo
28-Jan-11 5:23am
View
You can pass function pointer to any function template or not. But not as a template parameter(this should be a type could be a type of function pointer) template parameters being the ones in angle brackets <t1, t2=""> as opposed to function parameters in normal brackets (T1 arg1,T2 arg3)
ARopo
28-Jan-11 5:00am
View
Not sure what exactly it is you want to do. do you want to write a template class, a template function or something else? You might be better just trying it and then posting the code if there is a problem with it.
ARopo
26-Jan-11 6:23am
View
You have two options as I see it,
1 Get your C# to register as COM objects then call it from c++ (quite technical at the C++ end and problematic if the c# has user interface.
2 Write all the code in C++ - On the face of it probably the best option.
ARopo
13-Jan-11 4:12am
View
What is the problem now?
ARopo
12-Jan-11 9:51am
View
Find out what the value of j is when this exception is thrown
ARopo
12-Jan-11 9:47am
View
Your must be indexing out of the range of the array. not a vb expert if the array range is either 0 to readText.Length-1 or 1 to readText.Length
ARopo
8-Dec-10 10:25am
View
Good point didn't notice that, still what said about sizeof stands
ARopo
30-Nov-10 10:31am
View
Some code would be useful here, I don't clearly unstand you issue
ARopo
25-Nov-10 12:27pm
View
what is your problem?
ARopo
25-Nov-10 12:20pm
View
Also Favor Size or Speed Favor small(/Os)
ARopo
25-Nov-10 12:18pm
View
/01
Under project properties c/c++-optimization-Optimization Minimum Size(/o1)
ARopo
24-Nov-10 11:50am
View
It is not clear where WCF fits into this, Do you want to get rows from a database, send them over some network/internet then display the results in excel? Or just get rows from a database and display them in excel?
ARopo
16-Nov-10 8:48am
View
CComQIPtr just manages the release of the interface IPicture. You might want to repost this and give more detail on the IPicture interface
ARopo
16-Nov-10 4:59am
View
Some people seem to have a problem with your statement of urgentcy. People will answer your query as fast as possible adding urgent does seem to get a lot of people's backs up which is a shame because it is quite an interesting question.
ARopo
29-Oct-10 4:05am
View
How long does the query take if you do it in SQL on the database? If it takes a long time here the problem is with the database.
ARopo
29-Oct-10 3:41am
View
Do you have any sample code, it is very hard to help without any idea what your program does?
ARopo
21-Oct-10 4:10am
View
If it doesn't access a member variable then it should be static. Otherwise it will make maintence difficult e.g. some one in the future may change the function to access a member variable but not notice all the places where it is called without an instance
ARopo
20-Oct-10 8:42am
View
I agree that in practice NULL is nerely always 0 and nullptr is better if available. I don't like the refering to a pointer as 0 because 0 is a value where as the notion of NULL is no value more appt for a pointer. My main point was always initialise a pointer so you know what value it starts with otherwise you can't predict what value it will start with at runtime.
ARopo
20-Oct-10 8:35am
View
Am I going mad, if AgentFuntion is not static it will crash as soon as it accesses 'this' none of the other answers seem to agree, what is more a release build in VC6 for certain will contain a random address in baseClass. If the function is static then it would look much clearer like the CBaseClass::AgentFunction
ARopo
18-Oct-10 9:19am
View
We had problems with the dotnet framework compact edition using around 20mb even with a simple application, it seemed to be allocating the memory upfront to speed up the new command. in a dot net object have all the type information associated with them for use with reflection, maybe that is why your structured approach is paying off.
What OS is you device using?
ARopo
15-Oct-10 9:59am
View
Is Your timer tick reentrant (called before the last one finished)
ARopo
15-Oct-10 9:58am
View
Could it be something to do with serialPort1.ReadExisting()?
ARopo
15-Oct-10 7:32am
View
Thanks this is what I have done, but I was expecting a function to do it, Like in MFC CRect has a CenterPoint() function.
ARopo
15-Oct-10 7:09am
View
Just realised where I got the notion, in C++ MFG CRect has a CenterPoint function C
ARopo
11-Oct-10 4:57am
View
What language is it? It looks like a strange mix between c# and c++. If it is c++ then remove the public from the start of the function. If it is c# then why is there an #include and where is the class
ARopo
7-Oct-10 11:33am
View
Have you got ports C and B connected together then. Are they connected correctly? Do the port settings match?
Perhaps your serBread returns 0 because there is nothing to read.
ARopo
30-Sep-10 7:31am
View
Have you posted the correct code? I can't see any while loops here
ARopo
29-Sep-10 8:10am
View
I suggest you do some demo web applications that you can send links to along with your cv. Make a web CV and include it as a link in your standard CV. Do some of the free brainbox tests and include the results on your web CV.
Also add a skill summary clearly visible on the first page of your CV, I did a nice graphicical chart showing all my key skills and the amount of experience I had in each.
ARopo
24-Sep-10 8:38am
View
Personnally I like to group both private, and public functions into logical regions e.g. all method that deal with a partular control on a form
ARopo
23-Sep-10 4:47am
View
Have you tried
LightControl^ lighcontrol = (LightControl^)obj;
((ILightControl^)lighcontrol)->Settings();
ARopo
22-Sep-10 10:56am
View
It might help if you say what the problem with the code is.
ARopo
22-Sep-10 6:36am
View
Does the guid 27CC4E03-D86D-40B5-96D4-F7EA5B148A0D match the key in the registry?
ARopo
20-Sep-10 15:30pm
View
What is the exception? try going to the debug menu an check break when c++ runtime exceptions are thrown.
ARopo
14-Sep-10 10:44am
View
Games programming is also very broad. C++/WIN32 with DirectX libraries for game run-time and MFC or .NET for development tools. You can get DirectX for .Net but for performance reasons I don't think many games manufactures use this.
Show More