|
Smells to me like the sick machine is missing (or just can't find) errno.h which is where errno_t is defined. Without the SDK there may be a whole bunch of low level include files missing.
Happy hunting!
Peter
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
Sorry you being very silly for a programmer it isn't insanity it makes perfect sense
Look again at the error .. note the directories in particular
"c:\program files\windows ce tools\sdks\lync817_sdk\include\x86\stdlib.h"
There is nothing standard about and lets cover the basics
1.) The compiler is accessing files specific to some Windows CE SDK
2.) You are on a PC so you will need a SDK for Windows CE or the Compiler project settings are wrong
3.) The message is very clear what the problem is AKA it doesn't know what errno_t, it is an unknown type
4.) On a normal PC system errno_t is defined in the system file errno.h you use #include <errno.h>
5.) Being a system file the directories etc will be in the project settings as per note above.
Anyhow I am not a mind reader what you are doing but for some reason the compilation is using files in Windows CE SDK. Install the CE SDK if that is what you are doing or look at your project settings they are wrong. You could also just recreate the project from scratch on that machine it takes like 1 minute ... Create project from existing source is your friend.
In vino veritas
|
|
|
|
|
Leon - yes, yes, you are correct. It is for a CE, Windows Embedded Compact, a Smart Device, and let's see what does Microsoft call them now? Hmm IoT or something. Note:
Quote: If I create a simple smartdevice dialog application, my PC builds it fine
All of the defaults are set up by VS2008, so I admittedly was hoping for a "oh, yeah, I've seen that before" response. Nothing magic here, this is a completely default mfc dlg app that is the default framework of an application.
This is an argument between VS2008 and I think the SDK, and years ago, I solved this. Just having a senior moment.
Charlie Gilley
<italic>Stuck in a dysfunctional matrix from which I must escape...
"Where liberty dwells, there is my country." B. Franklin, 1783
“They who can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.” BF, 1759
|
|
|
|
|
Hello,
Recently, we move from VisualStudio 2010 to 2013.
I use Ultimate Toolbox that I have compiled it with Visual C++ 2013 in a lib. It compiles and links without problem.
When I link this lib with my program, I get a link error: LNK2019 unresolved external symbol. With Visual C++ 2010, the link process was correct.
The symbol is the MonitorFromRect Windows function in COXToolTipCtrl:: CalculateInfoBoxRect().
We runs on Windows 7 Professionnal 64 bits. We compile on 32 bits Visual C++.
Is there a way to bypass this problem?
Thanks for any help.
Claude
|
|
|
|
|
Gagnon Claude wrote: Is there a way to bypass this problem? Check your project settings to ensure the linker parameters are correct, and the library is included.
|
|
|
|
|
To elaborate on this suggestion, make sure that the linker uses the lib that you compiled with VS 2013, not the one that you compiled with VS 2010. The linker error may imply that it still sees the VS 2010 version. So, check the linker settings to see what search path it is using.
GOTOs are a bit like wire coat hangers: they tend to breed in the darkness, such that where there once were few, eventually there are many, and the program's architecture collapses beneath them. (Fran Poretto)
|
|
|
|
|
I don't think you meant this message for me.
|
|
|
|
|
Hi Claude,
The reason of the problem is that the code uses the definition of MultiMon.h for function MonitorFromRect instead of using the native definition of this function coming from WinUser.h. Solution : remove line "include MultiMon.h" from OXToolTipCtrl.cpp to force the usage of WinUser.h definition for this function.
Florianne
|
|
|
|
|
I open VS2015, click New Project, Select "Win32 Console Application"
Click OK.The dialog closes, then reopens.
Click OK.The dialog closes, then reopens.
Click OK.The dialog closes, then reopens.
.
.
.
C# apps work fine, just not C++,
Anyone seen this? Why can't I create a C++ console app?
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
Ya can't fix stupid.
|
|
|
|
|
What dialog do you mean? I don't have dialogs in my console apps and I've written a few hundred of them.
|
|
|
|
|
As I said, the New Project dialog
If it's not broken, fix it until it is.
Everything makes sense in someone's mind.
Ya can't fix stupid.
|
|
|
|
|
Visual Studio install has got corrupted somehow, go to Control panel on the Visual Studio entry do a repair. It usually fixes the problem.
In vino veritas
|
|
|
|
|
|
write a program that can be enter the password , if the correct password,the output will display "Your password is correct" if not the output will display "Your password is incorrect" and prompted to re enter a password.
this is my code but i still cant figure out what its prolblem.
#include <stdio.h>
int main()
{
int password=12345;
printf("Please insert your password:\n");
scanf("%p" , &password);
if(password=12345);
{
printf("Your password is correct");
}
if else(password!=12345);
{
printf("Your password is incorrect");
}
}
its say error expected '(' before 'else'..
kindly anybody can help me..please..
modified 27-Jan-17 9:56am.
|
|
|
|
|
Please read the sticky post (actually) just above yours: HOW TO ASK A QUESTION - C / C++ / MFC Discussion Boards[^]
Quote: Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
Quote: If you have a school or university assignment, assume that your teacher or lecturer is also reading these forums
You won't get code written for you here. Just try it yourself and tell us where you got stuck. Then we will try to help.
|
|
|
|
|
|
write it yourself and then ask here if you have specific problems
|
|
|
|
|
Member 12968703 wrote: its say error expected '(' before 'else'..
The error message already told what is the problem: just read it and check the code that it points out, in this case the else statement: that particular line is incorrect and needs fixing.
GOTOs are a bit like wire coat hangers: they tend to breed in the darkness, such that where there once were few, eventually there are many, and the program's architecture collapses beneath them. (Fran Poretto)
|
|
|
|
|
scanf("%p" , &password);
if(password=12345); {
printf("Your password is correct");
}
if else(password!=12345);
|
|
|
|
|
Also remove the semicolons following the right parens.
|
|
|
|
|
|
I mean the right parens on the lines with ifs.
The one on this line :
if(password=12345);
Will cause the printf to always execute.
|
|
|
|
|
I know, hence my , indicating my stupidity.
|
|
|
|
|
#include <stdio.h>
int main()
{
float number = 123456;
int pass;
printf("Please enter your password:\n");
scanf("%d",&pass);
if (pass==number)
{
printf("Your password is correct.\n");
}
else
{
printf("Your password is incorrect.\n");
}
}
i already write the program but i dont know how to make a prompted to re enter a password if i enter a wrong password..i really dont know..and i hope u can help me..
|
|
|
|
|
You do it be creating a loop, using a do , while or for statement. In pseudo code something like:
Set a retry count
While retry is not zero
Check password
If password is correct
Then break
Else
retry = retry - 1
If retry is zero
Then display error message
End While
See if you can turn that into C code.
|
|
|
|