|
You can adjust the numbers in the Visual C++ resource editor by going to properties, then putting '=x' after the name, where x is the number you want it to have (e.g. 'IDC_EDIT10=1000', without the quotes).
Stability. What an interesting concept. -- Chris Maunder
|
|
|
|
|
No better solution I believe... This one problem you need to avoid when using group radiobuttons.
MSN Messenger.
prakashnadar@msn.com
Tip of the day of visual C++ IDE.
"We use it before you do! Visual C++ was developed using Visual C++"
|
|
|
|
|
I have a DLL that I've made that doesn't work on other computers, saying from the VB application 'Run-time error 53: Export.dll not found'. I was told by someone yesterday that the other computer probably wasn't finding the external dependencies. So, even though the header files are included through #include directives and the paths to these files are added in my project settings, should I actually add these files to the project to make sure that my dll is standalone?
If it's broken, I probably did it
bdiamond
|
|
|
|
|
If indeed it is the case that other dependancies are required you will have to ship those DLLs with your application.
In order to find which DLLs you need, open "depends" and open your DLL into it. The tree will show all other DLLs on the system that your DLL depends on.
From that list you can determine which one(s) are missing on the other system.
Ant.
|
|
|
|
|
I kinda figured that, and I've used the dependency walker before, but what I'm trying to find out is if I go to the menu and click Project->Add to Project->Files... and actually make them a part of the project, will I still need to ship those files? Thanks for your help and patience with my idiocy
If it's broken, I probably did it
bdiamond
|
|
|
|
|
Unless you can find static lib versions of the DLLs then adding then you will need to ship the additional DLLs.
Ant.
|
|
|
|
|
alright, thanks!
If it's broken, I probably did it
bdiamond
|
|
|
|
|
Hi,
This snippet in my program...
USES_CONVERSION;
LPCTSTR lpSource = _T("123456");
char szSource[10];
strncpy(szSource,W2A(lpSource),MAX_PATH);
TRACE("%c",szSource[0]);
When I do unicode build TRACE throws error C2664: 'AfxTrace' : cannot convert parameter 1 from 'char [3]' to 'const unsigned short *'
Help me to solve this...
|
|
|
|
|
Your application is UNICODE, you passed an ANSI string to the TRACE call. Do:
TRACE(L"%c", ...);
or
TRACE(_T("%c"), ...);
Roger Allen - Sonork 100.10016
Strong Sad:
Clever I am? Next to no one.
Undiscovered and soggy.
Look up. Look down. They're around.
Probably laughing. Still, bright, watery.
Listed among the top. Ten.
Nine. Late night. Early morn.
Early mourn. Now I sleep.
|
|
|
|
|
Yep... it works...
In the following...
char str[][7] = {"123456",
"789012",
};
lstrlen(str[0]);
under unicode build throws error C2664: 'lstrlenW' : cannot convert parameter 1 from 'char [7]' to 'const unsigned short *'
How to handle this?
|
|
|
|
|
Yep... I found it...its
char str[][7] = {"123456",
"789012",
};
USES_CONVERSION;
int val = lstrlen(A2W(str[0]));
|
|
|
|
|
Manikandan wrote:
char szSource[10];
strncpy(szSource,W2A(lpSource),MAX_PATH);
You've got a buffer overrun bug waiting to happen there. You have a 10-char array but you're telling strncpy that you have MAX_PATH chars available, which is 260.
--Mike--
Personal stuff:: Ericahist | Homepage
Shareware stuff:: 1ClickPicGrabber | RightClick-Encrypt
CP stuff:: CP SearchBar v2.0.2 | C++ Forum FAQ
----
"Linux is good. It can do no wrong. It is open source so must be right. It has penguins. I want to eat your brain."
-- Paul Watson, Linux Zombie
|
|
|
|
|
Could someone explain why
m_ifField.nMask >> 1; would produce a warning saying "warning C4552: '>>' : operator has no effect; expected operator with side-effect". Shouldn't that code shift the bits in nMask to the right by one position? The nMask value is defined as a UINT .
- Aaron
|
|
|
|
|
You probably mean m_itField.nMask >>= 1;
|
|
|
|
|
I thought about that (and it does get rid of the warning), but in the MSDN documentation is has this little snippet
int nNumA=8;
nNumA >> 2; I figured that using >> would work on the actual bits of the left hand operand and there wouldn't be a need for assignment. If that's not the case any ideas when you would actually use >>? Thanks.
- Aaron
|
|
|
|
|
monrobot13 wrote:
...any ideas when you would actually use >>?
Well, it would be legal in the following case:
if (nNumA >> 2)
... This would shift the bits to the right 2 places and if the result was a non-zero value, it would do the ... stuff.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
For the same reason that none of these do either:
m_ifField.nMask & 1;
m_ifField.nMask ^ 1;
m_ifField.nMask | 1;
m_ifField.nMask ~ 1; Unless the result of these operations is assigned to a variable, the net result is they do nothing.
"The pointy end goes in the other man." - Antonio Banderas (Zorro, 1998)
|
|
|
|
|
Makes sense. Guess I just misunderstood the documentation. Thanks for the clarification.
- Aaron
|
|
|
|
|
Hi,
How can I print the icon?
DrawIcon()doesn't work with printer dc...
Regards
Neha
|
|
|
|
|
u can find nice stuff under bitmaps & palettes section...my favorite is Davide Pizzolato...
|
|
|
|
|
THis is the way I do it:
int xSize = (pDC->GetDeviceCaps(LOGPIXELSX) * 16) / 96;
int ySize = (pDC->GetDeviceCaps(LOGPIXELSY) * 16) / 96;
::DrawIconEx(pDC->m_hDC, x - (xSize / 2), y - (ySize / 2), m_pTemplate->GetIcon(), xSize, ySize, 0, NULL, DI_IMAGE | DI_MASK);
This will scale correctly for a preview and a print. although I have seen problems on some printers etc which do not use the mask correctly
Roger Allen - Sonork 100.10016
Strong Sad:
Clever I am? Next to no one.
Undiscovered and soggy.
Look up. Look down. They're around.
Probably laughing. Still, bright, watery.
Listed among the top. Ten.
Nine. Late night. Early morn.
Early mourn. Now I sleep.
|
|
|
|
|
Hi All
i have a CStringArray, which i had added 1500 items to
how can i loop through my array, retirving each individual item
please help, im being a bit thick today
ta
simon
|
|
|
|
|
durrr i said i was being a bit thick
for (int i = 0; i <= arr.GetUpperBound(); i++)
{
CString id= arr[i];
}
simon
|
|
|
|
|
for (int i = 0; i < cstra.GetSize(); i++)
{
CString s = cstra[i];
CString ss = cstra.GetAt(i);
}
|
|
|
|
|
Hi,
How to debug an application which is having multiple threads on windows paltform ?? Anybody got some clues??
Thx & Reg,
Satya
|
|
|
|