|
stringstream uses the locale information to do the conversion.
You can use _atof_l to achieve the same result.
«_Superman_»
I love work. It gives me something to do between weekends.
Microsoft MVP (Visual C++) (October 2009 - September 2013) Polymorphism in C
|
|
|
|
|
|
atof() is part of the standard C library that uses the general 'C' locale by default while stringstream is C++ which uses the current system locale by default. You can use the setlocale()[^] function to change the locale for the standard C library functions (pass an empty string to use the environment's default locale).
|
|
|
|
|
Hi all
I am trying to build a windows run time component which I need to link with a C static library.
It build fine when building in Win32 Release configuration.
but it generates following error when try to build in ARM Release configuration
"LNK2001 unresolved external symbol"
I have provided the path to .lib properly.
Can anyone please show me what I'm missing
Thank You
|
|
|
|
|
Please provide the full error message.
|
|
|
|
|
As the other reply stated, a full error message would be handy. Just a thought, you're definitely linking against a static library built for ARM as well ?
|
|
|
|
|
I used splitter to create 3 view in 2 rows.
1st row is splitted to 2 view and 2nd row is having only 1 view. But the view of 2nd row is attached to 0,0 position of main window. How can I repostion it to after 1 row?
|
|
|
|
|
See if this article (specifically steps 2 and 3) is of any help.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles
|
|
|
|
|
hi all,
Am new to MFC.I have an MFC application that has to capture the device/system shut down using MFC window messages.I tried it with wm_close,wm_destroy,wm_endsession.But not able to capture.The fix should be like it has to work in xp/vista and Windows 8.0. Thanks in advance
Naveen
|
|
|
|
|
|
Following code is at very beginning of "HessenbergDecomposition.h", which is a public library for calculating Eigen values.
Source code cab be viewed at this link.
namespace Eigen
{
namespace internal
{
template <typename MatrixType> struct HessenbergDecompositionMatrixHReturnType;
template <typename MatrixType>
struct traits <HessenbergDecompositionMatrixHReturnType <MatrixType> > { typedef MatrixType ReturnType;
};
}
}
VC++ compiler says:
E:\...\Eigen/HessenbergDecomposition.h(21) : error C2143: syntax error : missing ';' before '<'
E:\...\Eigen/HessenbergDecomposition.h(21) : error C2059: syntax error : '<'
E:\...\Eigen/HessenbergDecomposition.h(21) : error C2065: 'MatrixType' : undeclared identifier
E:\...\Eigen/HessenbergDecomposition.h(22) : error C2143: syntax error : missing ';' before '{'
E:\...\Eigen/HessenbergDecomposition.h(22) : error C2447: missing function header (old-style formal list?)
Is this c/c++ or UNIX/VC++ incompatible problem?
How to fix the compile error?
Thanks for code corrections.
|
|
|
|
|
|
The code is correct C++, except that this header file will only compile if included after Core, as it is in Eigenvalues:
#ifndef EIGEN_EIGENVALUES_MODULE_H
#define EIGEN_EIGENVALUES_MODULE_H
#include "Core"
...
#include "src/Eigenvalues/HessenbergDecomposition.h"
src/Eigenvalues/HessenbergDecomposition.h is not supposed to be included directly.
What is the cpp file that you're trying to compile?
|
|
|
|
|
Hello
This mass of data must be reduced with algorithms I do not know. Neural Networks works fine but in the last step I think.
Searching with Google I get Differential equations etc but this is not helpful. I need math formulars I can convert to code.
Has anybody advice ?
regards Peter
|
|
|
|
|
Hi,
This is my first posting at codeproject.com, so I apologize in advanced for any mistakes. I want to develop a simple C++ applications which can run for Windows XP, 7, 8. I want application to be simple to install and run on these platforms without a need for .net framework. Key here is nice skinned UI.
I did some research on topic and checked various applications you can download from the Internet and one that caught my eye is SlimCleaner at https:
cleaner.db 649 KB 9/15/2014 9:22 PM Data Base File
MyDefragDll.dll 649 KB 7/18/2012 6:47 AM Application Exte
service.db 7 KB 9/15/2014 9:22 PM Data Base File
SlimCleaner.exe 29,623 KB 7/10/2013 9:53 AM Application
SlimShell64.dll 673 KB 7/10/2013 9:53 AM Application Exten
SlimShell.dll 559 KB 7/10/2013 9:53 AM Application Exten
startup.db 10,841 KB 9/15/2014 9:22 PM Data Base File
My question is can somebody please help me understand what tools they used, what development environment, and API. Is it MFC, Winforms or WPF? The later two are .net, as far as I understand, but maybe they are just complied as stand alone application. Thing that this caught my sys is that .exe is 30MB is size. It appears that the whole application is in that single file!
As a new to Windows development I do not have a lot experience and if somebody also can give some hints and ideas when I see an application with the UI I like how to figure out what they used to develop it. I am not interested in reverse engineering the application, just to figure out is it MCF base, Winforms or WPF, is it done in Visual Studio or C++ Builder etc. Maybe what tools they used for skinning etc.
My knowledge in this area is limited at present so I apologize if I said something stupid.
Regards,
Terry
|
|
|
|
|
|
Thank you for your response. It is not an issue of weather to learning MFC or not, it is an issue of wanting to make a right choice up from. If I pick MFC and then later on I find out the Winforms would have been a batter choice it would not be a pleasant realization. MFC is being depreciated by Microsoft so it makes sense to pick something that is going to be around. Further due to the requirement to run on Windows XP, 7 and 8 without .net framework makes it questionable if Winforms or WPF can be used. On the other hand from what I have read it appears that there may be a way to compile a Winforms or WPF into a stand alone application which can be run without .net frameworks.
So before embarking on these adventures I thought to seek some advice and pointers from those who have sailed these waters before me. If I know for sure that let’s say Winforms can be compiled into a stand alone application which does not needs .net frameworks than that would be a good choice to pick. Thank you for your replay anyway.
|
|
|
|
|
Terry Milewski wrote: from what I have read it appears that there may be a way to compile a Winforms or WPF into a stand alone application which can be run without .net frameworks. Since both rely totally on the .NET framework I do not think that is correct. If you do not want to rely on .NET then C++ (with or without MFC) is your only real choice.
|
|
|
|
|
Hi ,
I'm trying to register 64 COM dll on 64 bit machine but it not get register with regsvr32. It gives error as follows
"The module 'C:\program Files\XYZ.dll' was loaded but entry-point DLLInstall was not found. Make sure that C:\program Files\XYZ.dll' is valid dll or OCX file and try again"
Dll exist at that path. On some 64bit it get registered.Please provide me a solution.
Thanks in advance.
|
|
|
|
|
|
Hello
I have written a client-server program using VC++ 2012 console application, which works on local network properly. But I want to connect to the server program on the internet using client program. I have the computer IP that server program is run on. How can I connect to server program by client?
(regards)
|
|
|
|
|
Exactly the same way you connect to it on the lan: by IP address.
|
|
|
|
|
Thank you for your advice, But it didn’t work. I decided to run server program on one of computers in my office. For this purpose I got that computer’s IP address from http://myip.dnsomatic.com and used it in server program. But error code 10049 was returned. (Cannot assign requested address) :
WSAData ws;
struct sockaddr_in sock;
int resSock, cl,bnd;
WSAStartup(MAKEWORD(2, 2), &ws);
resSock = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
if (resSock != INVALID_SOCKET){
sock.sin_family = AF_INET;
sock.sin_port = htons(3377);
sock.sin_addr.S_un.S_addr = inet_addr("86.57.x.y");
}
bnd = bind(resSock, (struct sockaddr *)&sock, sizeof(sock));
if (bnd != SOCKET_ERROR)
cout << "Successfull..." << endl;
else
cout << GetLastError() << endl;
|
|
|
|
|
zartosht_ppp wrote: I got that computer’s IP address from http://myip.dnsomatic.com and used it in server program. You should be using the address from the client to reach the server. And you cannot use the address "86.57.x.y", it does not mean anything.
|
|
|
|
|
That was just an example. I know it doesn't mean anything. anyway thank you for your guide.
|
|
|
|