Print Page | Close Window

GetString(ID_IDLE_TEXT)

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Command Bars
Forum Description: Topics Related to Codejock Command Bars
URL: http://forum.codejock.com/forum_posts.asp?TID=4819
Printed Date: 20 June 2025 at 5:49pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: GetString(ID_IDLE_TEXT)
Posted By: Detlev Schubert
Subject: GetString(ID_IDLE_TEXT)
Date Posted: 17 August 2006 at 7:18am
Hello,
 
why isn't it possible to get the  statusbar text for a Submenu ?
(see your example Multilanguage)
 
Private Sub Form_Load()
   CommandBarsGlobalSettings.App = App
   ResetCommandBars
   ' ... Code
   ' ...  Code
   StatusBar.IdleText = GetString(ID_IDLE_TEXT)
End Sub
 
Sub ResetCommandBars()
   Set ControlEdit = AddControl(CommandBars.ActiveMenuBar.Controls, xtpControlPopup, ID_EDIT)
   
   With ControlEdit.CommandBar
      AddControl .Controls, xtpControlButton, ID_EDIT_EDIT
      AddControl .Controls, xtpControlButton, ID_EDIT_SEARCH
         Set Control = .Controls.Add(xtpControlPopup, ID_DIENSTE, GetString(ID_DIENSTE))
         Control.CommandBar.Controls.Add xtpControlButton, ID_DIENSTE_COMPRESS, GetString(ID_DIENSTE_COMPRESS)
         Control.CommandBar.Controls.Add xtpControlButton, ID_DIENSTE_REPAIR, GetString(ID_DIENSTE_REPAIR)
         Control.CommandBar.Controls.Add xtpControlButton, ID_DIENSTE_BACKUP, GetString(ID_DIENSTE_BACKUP)
   End With
 
And please show me the right way to create a submenu, All your examples are not complete, because there ist not shown how to make a correct submenu. and the helpfile contents only funktions without any examples.
 
thx Detlev
 
PS: Example Code of the .rc-file
 
STRINGTABLE DISCARDABLE
BEGIN
   ID_DIENSTE_REPAIR       "Datenbank &reparieren...\nDatenbank reparieren\nDienste\nFragendatenbank reparieren"
END



Replies:
Posted By: Oleg
Date Posted: 17 August 2006 at 7:56am
Hello,
In Sample I added in AddControl
 
Control.DescriptionText = "Some text"
and see description for all controls... So obviously something with your descriptions in rc file.
 
 
In your sample ID_DIENSTE seems it is submenu.... So where is problem?


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Detlev Schubert
Date Posted: 17 August 2006 at 8:27am
Hello,
 
I asked it before ...
 
>> why isn't it possible to get the statusbar text for a Submenu ?
 
I have in my project 3 or 4 Submenus and in no one the statusbartext is shown when the mousecursor is on one of the submenuitems.
 
yes ID_DIENSTE is the ID for the beginning of the SubMenu like so..
 
ID_OPTIONS    ' MenuTitle ID
ID_OPTIONS_DATETIME
ID_DIENSTE
        |->      ID_DIENSTE_COMPRESS  'here is NO statusbar ID_IDLE_TEXT
        |->      ID_DIENSTE_REPAIR        '  and not here
        |->      ID_DIENSTE_BACKUP       '  and not here
ID_OPTIONS_SOUND
....
....
 
The RC-File is correct compiled as a DLL. Sample please see my last posting. In all other menu's statusbar ID_IDLE_TEXT works correctly and only in all submenu's it works not correct, why ?
I hope you unterstand that problem.
 
thx Detlev


Posted By: Oleg
Date Posted: 17 August 2006 at 8:36am
Hello,
 
In code you attached you set only caption but not description text.
 
Instead
 
Control.CommandBar.Controls.Add xtpControlButton, ID_DIENSTE_COMPRESS, GetString(ID_DIENSTE_COMPRESS)
call
 
AddControl Control.CommandBar.Controls, xtpControlButton, ID_DIENSTE_COMPRESS


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Detlev Schubert
Date Posted: 17 August 2006 at 9:20am
Hi Oleg,
 
YES.. that's it .. it works .  You are my hero.
 
Thx very much
Detlev



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net