Solved

Settings new resource.

Posted on 2000-03-12
3
178 Views
Last Modified: 2013-11-20
In my project to adopt it it to europian languages,i am using dll of that respective languages,i.e. i am using all same resources ,with ids & evry thing ,only caption in that perticulat language.
I am loading DLL with LoadLibrary,
Setting those resouces with AfxSetResourceHandle.
Dll get loaded ,all dialog boxes works, but that main menu bar doesnt changle ,i used DrawMenuBar to redraw menubat,it doesn't work

thanks.
0
Comment
Question by:jaydeep
3 Comments
 
LVL 8

Expert Comment

by:VinExpert
ID: 2610738
Hi,

Just give it a try...

U get the menu resource handle in a CMenu.

Then use AfxGetMainWnd()->SetMenu(...);
And then use DrawMenu();

Try it out.

VinExpert
0
 

Accepted Solution

by:
TG earned 15 total points
ID: 2611487
Hi,
I thing it's work properly, but the problem is that you did not change Handle to Menu in the MainFrame, so you see old one menu.

If you want to see menu on the correspond language you must change menu handle in Mainframe with that one that you load from the new DLL.

Also you need to change all menu handles in all DocTemplates that you have in the application.

Do not forget to send message to active child that menu is changed( if this is a MDI ).

TG
0
 

Author Comment

by:jaydeep
ID: 2614757
Hi
i have tried forst option of setmenu  earlier it doesn't work.
Actually GetMenu returns the present active menu, so it return menu of view ,or you can say child.but don't know why it's not working.

Another question when we load resurces from DLL,  have copies same .rc file of apllication  & copied it to DLL .rc & i have just changed the captions.

can you suggest some other solution

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Question regarding Copy/Paste 16 91
ASCII Non-Printable characters/codes and their HTML equivalents 6 104
has77  challenge 9 71
noX challenge 17 91
Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now