Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8525763
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T08:04:42+00:00 2026-06-11T08:04:42+00:00

I am working on a MFC project with multiple GUI applications. The objective is

  • 0

I am working on a MFC project with multiple GUI applications. The objective is to move all the resources from individual projects to a single resource dll.

After some change I have a single resource-only dll project and multiple GUI project. Each GUI project is using the following code to access the resource dll:

BOOL CFooApp::InitInstance()
{
    HINSTANCE hRes = NULL;
    hRes = LoadLibrary(_T("Resource.dll"));
    if(hRes) AfxSetResourceHandle(hRes);
    ....

So far things work fine except there are two issues:

  1. The GUI exe files lose there icons in Windows explorer. Although there are some MFC boilerplate code that load the icon from IDR_MAINFRAME, that only affects the icon in the top
    of the application window.
  2. The Class Wizard won’t work anymore. For example I can no longer click on a dialog button in the resource view to add a button handler?

How to solve these issues?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T08:04:43+00:00Added an answer on June 11, 2026 at 8:04 am

    Now I am using a simple method that almost solved the problem. I just add the central rc file (e.g. Resource.rc in my above example) to each GUI project. Thus: 1) The ClassWizard can be used. 2) Icon are generated for each GUI. 3) Although the GUI project is referencing to a English version rc file, the GUI exe can still load a Resource.dll in other languages. The only draw back is every GUI now has the same icon, presumably the first icon they found in the rc file.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on an MFC Visual C++ project. As I understand from MSDN ,
I am working on an old MFC project. Users are using Windows 7 they
I am currently working on an already developed project written in MFC C++ and
I'm working on a win32/MFC project. I have a custom CListCtrl control that I
I'm working on updating the GUI of a native (MFC) application using .NET and
I'm currently working on a C++ MFC project on visual studio 2003. The aim
I am working on a legacy project in VC++/Win32/MFC . Recently it became a
I'm working on a project that is using the Qt/MFC Migration Framework and I'm
So I'm working on a class project that uses MFC. I never had to
Currently I am working in a project that uses MFC a lot, but it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.