Button bar opens as text file

English support forum

Moderators: white, sheep, Hacker, Stefan2

Post Reply
joelEis
Junior Member
Junior Member
Posts: 3
Joined: 2021-11-30, 16:36 UTC

Button bar opens as text file

Post by *joelEis »

My issue:

1. I have a button on my main (Default) button bar that opens a secondary button bar.

2. Everything was working fine until I moved to a different computer and had to install TC under a different path:

3. I copied my button bar files and changed the paths where necessary for the new installation location.

4. Now, when I click the button on my main (Default) button bar to access the secondary button bar, the secondary button bar opens as a text file.

Any suggestions?
User avatar
Stefan2
Power Member
Power Member
Posts: 3405
Joined: 2007-09-13, 22:20 UTC
Location: Europa

Re: Button bar opens as text file

Post by *Stefan2 »

joelEis wrote: 2021-11-30, 16:48 UTC Any suggestions?

Maybe a Hello! first?




 
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3741
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Re: Button bar opens as text file

Post by *sqa_wizard »

1. Check the settings of your button on my main (Default) button bar to access the secondary button bar.
The command must end with bar.
By chance it ends with txt

2. Perform a doubleclick on a BAR file.
=> Does it open as text file ? => you have assigned BAR extension to a text editor by mistake
Last edited by sqa_wizard on 2021-11-30, 19:10 UTC, edited 1 time in total.
#5767 Personal license
joelEis
Junior Member
Junior Member
Posts: 3
Joined: 2021-11-30, 16:36 UTC

Re: Button bar opens as text file

Post by *joelEis »

Yes, the problem seems to be that .bar is associated with a text editor. Unassociating it is a separate issue that I will have to deal with. This is a company computer and every thing I try seems to violate some company security restriction.
User avatar
Horst.Epp
Power Member
Power Member
Posts: 4664
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Re: Button bar opens as text file

Post by *Horst.Epp »

joelEis wrote: 2021-11-30, 18:38 UTC Yes, the problem seems to be that .bar is associated with a text editor. Unassociating it is a separate issue that I will have to deal with. This is a company computer and every thing I try seems to violate some company security restriction.
Sorry, but that makes no sense.
No security rule forces one to assign a text editor to a certain extension.
Windows 11 Home x64 Version 21H2 (OS Build 22000.438)
TC 10.00 x64 / x86
Everything 1.5.0.1295a (x64)
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3741
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Re: Button bar opens as text file

Post by *sqa_wizard »

You may work around with TC internally:
Just use "Files - Internal associations (Total Commander only)"
Add "*.bar* and let it empty or remove unwanted entries
#5767 Personal license
User avatar
Dalai
Power Member
Power Member
Posts: 7904
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Button bar opens as text file

Post by *Dalai »

Uh, what is the command on your button that is supposed to open the secondary bar? It should be

Code: Select all

OPENBAR D:\rive\some\file.bar
My guess is that you don't have OPENBAR as the command on that button, hence it's opened in the associated program.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups - Download-Mirror
User avatar
Gral
Power Member
Power Member
Posts: 922
Joined: 2005-01-26, 15:12 UTC

Re: Button bar opens as text file

Post by *Gral »

Dalai wrote: 2021-11-30, 19:18 UTC Uh, what is the command on your button that is supposed to open the secondary bar? It should be

Code: Select all

OPENBAR D:\rive\some\file.bar
My guess is that you don't have OPENBAR as the command on that button, hence it's opened in the associated program.

Regards
Dalai
OPENBAR command is not needed to open one button bar from another. Note that OPENBAR command was introduced with TC 7 while open buttonbar by button on bar is possible starting with WC 4
Also associate BAR files with text editor doesn't harm to anything - called as a command from buttonbar TC handles BAR files internally.
There's something wrong with OP system/TC.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 41862
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Button bar opens as text file

Post by *ghisler(Author) »

The behavior is different with OPENBAR when the linked .bar file is invalid, e.g. because the [Buttonbar] section header is missing:
1. Without OPENBAR, TC will try to open the .bar file with the associated program
2. With OPENBAR, you will get an empty button bar

So my guess is that the linked .bar file is damaged somehow. Please open it with F4, it should start like this:
[Buttonbar]
Buttoncount=<number of buttons>
button1=<dll or exe name>,<index>
cmd1=<a command>
iconic1=0
menu1=label
button2=<dll or exe name>,<index>
etc.
Author of Total Commander
http://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8647
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Button bar opens as text file

Post by *MVV »

Horst.Epp wrote: 2021-11-30, 19:01 UTC No security rule forces one to assign a text editor to a certain extension.
Actually there is a problem 'cause Windows 7+++ doesn't allow just to remove association with a program, the stupid new association editor only allows changing it to another program, and it doesn't even set an icon for an extension. :D
Post Reply