Message 1 of 2
MFC Resource labels not set

Not applicable
02-28-2002
10:28 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
another question about ARX & MFC:
We use an ARX extension dll (dynamically linked), we reproduce exactly the
MFC
example, using TemporaryResourceOverride and module state managing.
When executing the application, the labels of the button with IDOK, IDCANCEL
and
IDC_STATIC have some random text. All the rest is correctly shown. Since i
rename,
i.e. IDOK resource to IDOK_MYUNIQUEANDVERYSPECIALRESOURCE,
all works fine. It looks to me like a resource handling problem, but i
cannot figure out
where it is:
my main file:
...
DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
{
// Remove this if you use lpReserved
UNREFERENCED_PARAMETER(lpReserved);
if (dwReason == DLL_PROCESS_ATTACH)
{
_hdllInstance = hInstance;
CTemporaryResourceOverride::SetDefaultResource(_hdllInstance);
...
and when creating dialog:
...
CTemporaryResourceOverride temp;
DlgLogin dlg;
...
theArxDLL.AttachInstance(hInstance);
Thanx,
Wolf.
another question about ARX & MFC:
We use an ARX extension dll (dynamically linked), we reproduce exactly the
MFC
example, using TemporaryResourceOverride and module state managing.
When executing the application, the labels of the button with IDOK, IDCANCEL
and
IDC_STATIC have some random text. All the rest is correctly shown. Since i
rename,
i.e. IDOK resource to IDOK_MYUNIQUEANDVERYSPECIALRESOURCE,
all works fine. It looks to me like a resource handling problem, but i
cannot figure out
where it is:
my main file:
...
DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
{
// Remove this if you use lpReserved
UNREFERENCED_PARAMETER(lpReserved);
if (dwReason == DLL_PROCESS_ATTACH)
{
_hdllInstance = hInstance;
CTemporaryResourceOverride::SetDefaultResource(_hdllInstance);
...
and when creating dialog:
...
CTemporaryResourceOverride temp;
DlgLogin dlg;
...
theArxDLL.AttachInstance(hInstance);
Thanx,
Wolf.