|
Hello, i have a problem.
I am currently developing software for several platforms in msvc 7.1. It seems its not possible to add a platform of your own definition by just "adding" it in the configuration manager, only the predefined platforms works, such as Win32, x64, etc. If you type a name of your own in the platform field when creating a new one, you cant select that platform for any of the projects when you want to setup new debug/release configurations for that platform.
Must a new platform somehow be registered with visual studio?
Thanks
Peter
|
|
|
|
|
Well, there's more to a platform choice than a name. It's associated with all sorts of thngs. Which compiler, debugger, virtual machines (ie PDA emulator), etc.
So I think there will have to be all sorts of settings associated with them. Which reinforces your idea about registering a platfrom with VS.
How you do *that* is another question. (For someone cleverer than me).
|
|
|
|
|
Dear Friends,
I m working VC++ where UNICODE is not defined for tht particular application.
I want to display "Name (DownArrow)" as a caption on a control. here Downarrow means the picture of downarrow.
I tried in a following way.
CString s1, s2;
s1 = _T(2193);
s2 = "PickUp" + s1;
But for S1 it is giving me the character with value as 255.
Can anybody help me out?/
I can use painting tht control but i don't want to do that..
Thanks in advance
Megha
|
|
|
|
|
megha_gharote wrote: s1 = _T(2193);
what are you expecting with this ?
|
|
|
|
|
in character map this value corresponds to downarrow.. so i thought by doing
s1 = _T(2193); i m ay get tht value as CString in s1...
|
|
|
|
|
do you know what the _T() macro does ?
it simply prepends a L in front of the string (because you're supposed to pass it a literal string, not an integer) if UNICODE is defined, and does nothing otherwise.
|
|
|
|
|
toxcct wrote: it simply prepends a L in front of the string (because you're supposed to pass it a literal string, not an integer).
Oh no. Prepends nothing in his case.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
OMG, i forgot to finish my sentence ! lol. fixed now
|
|
|
|
|
You're trying to do a pretty weird thing.
Since your application is not set as a UNICODE build, the macro _T expands to nothing and you'll get s1 = (2193) ;
and this shouldn't ever compile.
BTW UNICODE value for down arrow is 0x2193 , i.e. 8595.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
Hi All
is there anyway to stop the Open File - Security Warning from not appearing
when someone first uses my application ?
You can get round this after by remove the tick, in the check box
but i would rather it not appear at all
Can anyone help
Simon
|
|
|
|
|
Which open file security warning?
Greetings.
--------
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
“The First Rule of Program Optimization: Don't do it. The Second Rule of Program Optimization (for experts only!): Don't do it yet.” - Michael A. Jackson
|
|
|
|
|
|
Hi Experts,
How can I rename a file thorugh any API.
|
|
|
|
|
You can use of SHFileOperation or rename .
|
|
|
|
|
I used the code below but it does not rename the source file even it creates another file (spacifies in To).
SHFILEOPSTRUCT sfo; <br />
ZeroMemory ( &sfo, sizeof (SHFILEOPSTRUCT)); <br />
sfo.wFunc = FO_RENAME ;<br />
sfo.pFrom = _T("g:\zz.txt\0");<br />
sfo.pTo = _T("g:\pp1.txt\0");<br />
SHFileOperation(&sfo);
|
|
|
|
|
hmmm...
maybe remove the "\0" ?
|
|
|
|
|
pther wrote: sfo.pFrom = _T("g:\zz.txt\0");
sfo.pTo = _T("g:\pp1.txt\0");
Should be:
sfo.pFrom = _T("g:\\zz.txt");
sfo.pTo = _T("g:\\pp1.txt");
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
i have a
CSocket SomeSocket; variable declared globally in a "one.h" file.I have inlcuded this one.h in one.cpp as
#include "one.h"
I used this SomeSocket in another two.h files where i have included the file
#include "one.h"
now i get a linker error stating
two.obj : error LNK2005: "CSocket SomeSocket" (?xst@@3UGlobals@@A)
already defined in one.obj
what was the mistake.
-- modified at 6:54 Friday 30th November, 2007
Adi Vishayam
|
|
|
|
|
You need to put include guards in your header file:
#ifndef YOURFILE<br />
#define YOURFILE<br />
<br />
<br />
#endif
(replace YOURFILE by something unique, like the file name).
You could also use #pragma once for microsoft compiler.
|
|
|
|
|
Cedric Moonen wrote: You could also use #pragma once for microsoft compiler
#pragama once is already added.
problem remains the same.
Adi Vishayam
|
|
|
|
|
you have to declare it extern inside your include file (i.e. "one.h" )
extern CSocket SomeSocket;
and then define once inside a single source file (e.g. in your "one.cpp" ).
CSocket SomeSocket;
The mistake is in your include file: as it stands CSocket SomeSocket is defined in multiple source files.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
CPallini has given you the correct answer.
But I see this mistake a lot with novice programmers.
The linker is complaining because (as it says) you have two instances of SomeSocket.
Before the compiler attacks you "one.c" file, a preprocessor attacks it, and processes the includes.
An easy exercise for you: remove the #include from one.c, and cut and paste the whole of one.h into the top of one.c.
Do this for two.c. Now have a lightbulb moment as you realise what the linker is telling you.
Iain.
|
|
|
|
|
Hello to all,
I have designed one modeless dialog box which will get invoked after clicking one button and will get destroyed after some time automatically, now i have inserted a progress bar on this dialog box and i want that untill and unless this dialog box is existing it should show the progress bar with process of progress, now the problem is that progress bar is getting displayed on dialog box but it is not showing the process of progress. how to do it? can we insert progress bar on modeless dialog box? can any body help me plz?
Thanks and Regards,
Anay
|
|
|
|
|
Insert a Timer function in which the bar gets updated. 100ms is a nice value.:->
Greetings from Germany
|
|
|
|