summaryrefslogtreecommitdiff
path: root/protocols/CurrencyRates/src/CreateFilePath.cpp
blob: 71490432a903f9b8c987151c22bc75d9d2eeb8ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include "StdAfx.h"

tstring CreateFilePath(const tstring &rsName)
{
	wchar_t szPath[_MAX_PATH];
	::GetModuleFileName(g_plugin.getInst(), szPath, _MAX_PATH);

	wchar_t* p = wcsrchr(szPath, '\\');
	if (p)
		*p = 0;

	tstring s(rsName);
	FixInvalidChars(s);
	tostringstream o;
	o << szPath << L"\\CurrencyRates\\" << s;
	return o.str();
}