|
Can I ask what CPMRU is short for?
|
|
|
|
|
It is a 'private' joke. It means "Code Project Mind Reader Unit". It appeared recently because a lot of questions that were asked were so incomplete that you had to either see the screen of the guy or read his mind
|
|
|
|
|
Cedric Moonen wrote: you beat me to it
Using Sticks??
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You/codeProject$$>
|
|
|
|
|
You could also use a COleDateTime[^] object: you "load" the date using the ParseDateTime method and then you can retrieve all the information you need using the different member functions.
The big advantage is that it checks for the date validity, which is a pain if you have to do it yourself (months don't have the same number of days and you have to take into account leap years too ).
|
|
|
|
|
Thank you. I shall look into ParseDateTime. Didn't know about that! Although for now, what you showed me (left,right, mid) is perfect for what I am trying to do.
Thanks,
Tara
|
|
|
|
|
Tara14 wrote: what you showed me
It was not me
Anyway, it all depends from where your date is coming from: if it entered by a user of your program, then it is better to check its validity.
|
|
|
|
|
|
I dont think you can add CDialogBar to Cdialog.
Yes CDialogBar can be floating. and offcourse you can show and hide it as a normal window.
If you stick to CDialog i dont think there is any easy way.
|
|
|
|
|
Hi,
I'm using VS 2005 to create a win32 application.
Now that i have my exe running i'd like to deploy my application and make it run on a dev-free environment.
Does anyone have an idea how to detect the exe dependencies? Of course i've used the dependency walker and i've got a list of dlls that need to sit in the app dir beside my exe. But still, my exe won't run outside visual studio and i get "abnormal program termination".
I'd highly appriciate your help.
Thanks.
Snir.
|
|
|
|
|
You have to execute vcredist_x86.exe on the target machine. This will install the C-runtime and MFC libraries on the target machine. You can download it from here[^] (scroll down if you have SP1 installed for visual studio).
You need of course to distribute the release version of your programs.
|
|
|
|
|
|
It doesn't sound like dependencies are your issue. If I were you I'd build a Release build of your project but switch Debugging information on (Program Database). Make sure your project has the path to the CRT source code ( You did install it with VS 2005 didn't you ) in it's includes. Run the release build and when it tries to quit on you attach the debugger and see if you can figure out what's going on. There are not that many possible causes for "abnormal program termination" on startup so you've got a reasonable chance of cracking it. Did you try to use the CRT file system during static initialization or try to allocate a negative or > 0x7FFFFFFF amount of heap memory? Those are the sorts of things that might silently fail in Debug but may blow you out of the sky in a Release build.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Thanks for your reply.
My release version runs smoothly from within VS. Problems like those you describe would have prevented it from initializing properly even from within VS. Hence my guess that it has to do with the enveloping CRT environment.
Running the exe from outside VS fails! Even on a computer that has a full VS installed.
Snir.
|
|
|
|
|
The normal expectation would be that running the Release build from within VS and running the Release build on a computer with VS installed are the same thing. You could always try the catchall solution of turning off incremental linking in your project settings and doing a full rebuild. The CRT environment is what's keeling over but that is essentially just a statically linked library or an implicitly linked Dll depending on your project settings ( Make sure if you have multiple modules that the CRT settings are consistent throughout ) Beyond that it's not to easy to get the old veteran that is MSVCRT.DLL to fail in such an arbitrary manner.
Nothing is exactly what it seems but everything with seems can be unpicked.
|
|
|
|
|
Can anybody tell me how I can realize a certain computer?
I mean maybe it's possible to define an unique code for any computer.
|
|
|
|
|
what are you trying to do ?
I really don't understand your question.
|
|
|
|
|
|
Usef Marzbani wrote: I mean maybe it's possible to define an unique code for any computer.
I do not think that you will be able to generate a guaranteed unique value for ANY computer. You might be able to get a "good enough" identifier by looking at a system's hardware and software.
For example, if you want to lock a software application to a certain system, you could look at things that are less likely to change, like:
o Geometry of the Windows System drive
o CPU Serial Number (if supported by the CPU)
o First NIC's hardware address
o results of the CPUID instruction
o Installed Memory
Choosing a value that changes easily, like number of hard drives or drive letters, swap file size, etc., is a sure-fire way to piss off your users if they have to re-validate their license each time this happens.
Peace!
-=- James Please rate this message - let me know if I helped or not!<hr></hr> If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! See DeleteFXPFiles
|
|
|
|
|
Hi,
Is it possible to embed VERSIONINFO informations in a c# project ?
I tried integrating the .rc file in my project, and modified the generation action to 'embedded resource' but the binary still show the assembly version
|
|
|
|
|
There is a specific forum for C++/CLI .NET questions and this is not it. Have look at the forum titles.
I have not tried to import an existing RC file but if you create a new C++ managed winforms project it has an RC file which you can add a VersionInfo section into so it is supported some way.
VS2005 on XP Pro
|
|
|
|
|
oh sorry, I was confused where to put this question, so I posted it twice
yes, you are right! this work in a manged c++ porject, but that's not what I need, I already invested more than 3 months in c# and I am not ready to move to c++ just for this
|
|
|
|
|
So you are doing C# development? Don't take this the wrong way but in the 44 minutes since your first post I could have have easily manually copied the Version Information values from a RC file into the Version information of the AssemblyInfo.cs file.
|
|
|
|
|
I am sure you can do that
In my case, I am using a shared version.rc file generated on the fly by the server doing the compilation.. this is getting a little more complicated
|
|
|
|
|
|
Thanks mike, I appreciate it
|
|
|
|