All pastes #759370 Raw Edit

Someone

public cpp v1 · immutable
·published 2007-11-03 01:56 UTC
rendered paste body
float getIniValueAsFloat(LPCSTR section, LPCSTR key, LPCSTR iniFile){	DWORD length = ::GetPrivateProfileString(section,  key, "0", (LPSTR)s.c_str(), length, iniFile);	if(length > 0)	{		TCHAR* value = new TCHAR[length + 1];		::GetPrivateProfileString(section,  key, "0", value, length, iniFile); 		return  atof(value);	}	return 0;}