|
That was a really eye opener for me. What I know from experience VC++ debugger is the most reliable one. Any way it was a great message.
|
|
|
|
|
Hi
In remoting we cannot register more than one object to the same port. If we have to expose number of object over remoting we end up in opening lot of ports. Its there is a way in .NET remoting so that I can register more than one object on same port? Or should I have to change my design so that I aggregate objects in parent and expose the parent by remoting ?.
Umesh.b
|
|
|
|
|
Are there any tools in VS .NET or somewhere else to merge a bunch of assemblies together to create just one? If you know any resource for this, please let me know. Thank you.
Example:
Assembly1.dll + Assembly2.dll --> newAssembly.dll
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
Take the source code of each assembly and put it all in one project. Then compile it all into one assembly.
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
One project is in J# and another is in C#. How can I combine them in a single project!
|
|
|
|
|
Hmmm... Rather than just a straight forward "How do I do..." kind of question, what are the reasons behind it? Give me the history behind the question. Often in software development the final solution is more of a compromise of what you would like and what the situation will allow.
Why do you want to combine the two assemblies in to one? Why was one developerd in C# and the other in J#? What about just making one a dependancy of another? Or, allowing a third assembly that is dependent on the first two?
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
There are no specific technical reasons and I just this is a request that must be done.
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
Arash Sabet wrote:
this is a request that must be done
I don't think there is an easy answer to this. If a command from on-high has demanded that it must be done then it doesn't sound like the on-high commander has a great technical understanding.
Different .NET languages cannot be combined in the same project (to the best of my knowledge). The best I can offer is that the smaller one is rewritten into the language of the larger assembly and recompiled.
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
Can al.exe combine two assemblies as a single one?
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
Not out of the box... But if you look up MSDN for "Multifile Assembly Example" you will find how to create lots of MSIL module files, which can be used by the AL.EXE tool - So putting the two original assemblies together may just be possible if you can compile each to a MSIL module first and then use AL.EXE to link the modules together to make the assembly.
Mayme this is just me - but this seems like a bit of a hack. I'd still really like to know the reasoning about why these two assemblies must be made into one. I don't see that it matters having two assemblies instead of one. I think it would be a lot easier to manage as two assemblies rather than as two masquerading as one. I'm not sure about how the debugger will take to this arrangment (it might be clever enough to work out where everything is - but it could also really confuse it).
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
Thanks for the reply.
As a matter of fact I have been requested to make it and I have not asked about the reason. I agree with you but I have to keep on mixing those.
Regards
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
And by the way,
If you wouldn't mind I have another question. I have an MFC project that works well. Then I wrapped it by Managed C++ and it work well too. But something small is wrong with the wrapped project. When I open the generated MC++ assembly by .NET object browser there are a bunch of other stuff exposed into the object browser that I believe they're done by MC++ compiler. Is there any way to hide them?
Thank you.
P.S. Are you in either Canada or the US?
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
And by the way,
If you wouldn't mind I have another question. I have an MFC project that works well. Then I wrapped it by Managed C++ and it work well too. But something small is wrong with the wrapped project. When I open the generated MC++ assembly by .NET object browser there are a bunch of other stuff exposed into the object browser that I believe they're done by MC++ compiler. Is there any way to hide them?
Thank you.
P.S. Are you in either Canada or the US?
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
Hi,
If you look up the .NET Framework Class Library in MSDN for the "EditorBrowsableAttribute Class" you'll find details of an attribute to make stuff invisible to intellisense.
For example:
[EditorBrowsable(EditorBrowsableState::Never)]
__property int get_Age()
{
return ageval;
}
Should never show up in intellisense.
Finally, I'm on the other side of the Atlantic in Scotland. (click on the wee head next to my name for a link to my bio)
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
What I mean is hiding _ABC, AFX_CLASSINIT ,ATL , CDC ,etc from object browser while exposing the mixture of managed and unmanaged DLL contents.
Regards
P.S. Enjoy your nice weather. We are freezing here buddy. Last night it was miunus 16. It's nothing comparing February. Somedays we have -35 with wind chil factor.
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
These are generated by macros so guess it would mean redefining the Macro. Although for some you might be able to get away with putting the Attribute in front of the Macro (as some expand out to just function definitions)... If I recall MFC correctly (it has been some time since I used it)
Well, its not as bad as -16. Last night it was -4C. In fact we've not had a really cold winter since 1995/6 and then it got down to -20C in the central belt [The corridor between Edinburgh and Glasgow] and much colder in the Highlands. That followed a really excellent summer as I recall. This year has had an excellent summer. So if the cycle holds then it'll be just the right temeperature for bursting pipes when I go on holiday.
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
Thank you for the reply. I hope you do not have a cold winter this year. I can't wish this for our winter in Toronto because either I wish or not the terrible winter shows up. Worse than that is our vehicle. They put ice salt on the streets and it covers the entire body of the vehicel. I spent an hour to take the salt off my Honda Civic body. (My nice car was so dirty )
By the way, have you ever been here?
Regards
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
Yes, I was in Toronto in the Summer of 2000. I also did a tour up the thousand islands, over into New York State and toured around the Addirondacks then along the south of the Great Lake (the name escapes me), and back into Canada at Niagra Falls. Also took in a couple of days up by Lake Huron. It was a really nice holiday.
I stayed in a B&B near Kingston for a couple of night that was run by a really nice couple. She did the B&B stuff but he was a professional chef and I have never had so much great food. When I went down for breakfast he had about 6 types of bread on offer, all baked within the last hour. That was truely awsome hospitality.
Have you ever been to Scotland?
--Colin Mackay--
"In the confrontation between the stream and the rock, the stream always wins - not through strength but perseverance." (H. Jackson Brown)
Enumerators in .NET: See how to customise foreach loops with C#
|
|
|
|
|
So you had a great time here! No, unfortunately I have never been in Scotland. I'm planning to come over there ( Both England and Scotland )some day. Anyways stay in touch...
Regards
Arash Sabet
Computer Engineer
E-mail: afifi@sympatico.ca
|
|
|
|
|
I was just wondering if the Framework includes the compiler in some set of wrappers. I'm writing a utility that needs to be able to compile solutions written in VB.NET and C# for use at the office and would like to have a custom class to do compilations. I was just wondering whether it's there or not. Of course I can always write a class wrapper that handles the existing compiler and possible command lines (which is what I'm going to do for the short term) but I was just wondering... I'm always finding something in there I didn't expect.
|
|
|
|
|
You will find the C# compiler at path
C:\WINNT\Microsoft.NET\Framework\v1.0.3705\CSC.exe
"v1.0.3705" may vary depending on the version of .NET Framework installed.
|
|
|
|
|
I'm writing a simple little c# class to simply function as an alarm - you pass it a System.DateTime with the constructor, and when that time is reached, it fires an "Alarm" event. Simple enough. However, what's the most efficient way of doing this? Currently, I have thought of two ways. The first has a timer within the class that raises it's event every second or so, and each time it checks to see whether the time now is the same as the target time (accurate to the minute essentially, which is all that's neccesary).
The second is to work out how many milliseconds is between the time the control is enabled, and the target time, and set the interval to that. With repeat turned off, this means that in theory the timer will fire when the alarm is due, which is maybe more efficient than regular comparison checking?
Are these both crazy? Which is more sensible? Is the System.Timers.Timer accurate enough to do the second option anyway?
Am i missing a very easy way of doing this that is nothing like the above? Thank you very much in advance for any comments.
|
|
|
|
|
There doesn't appear to be any clear "best" way of dealing with this kind of thing. I have a couple of Windows Services that have to do various things at "scheduled" times. At the time I needed to write them, I chose the services route. Who knows now whether another method would have worked better... but from my experience it doesn't matter much. I run a timer as you suggested. Since my timing is accurate to the minute (not second) then I fire the timer every 60 seconds. Start the timer when the application starts and let it go with that. Don't use the Forms Timer. Use one of others. They're much better (like the System.Timers or the System.Threading.Timers).
Another option (which I could have taken) is to use the .NET framework wrappers for the Windows Scheduler service. There's an article on here all about that. Then you can write an application that runs when it's scheduled to and that's it. Simple as you please as long as the user is letting this service run.
|
|
|
|
|
This isn't really a framework related question and besides you have already posted the same question to the C# forum.
|
|
|
|
|
Many apologies for any annoyance caused by a double post - I couldn't decide whether this was more of a general framework question or not. I happen to implement in c#, so posted there first, but thought that then it might be more appropriate as a general question of technique. Again, apologies for offence caused!
|
|
|
|