Ask Your Question
0

button has dotted lines on it

asked 2019-02-07 23:43:51 +0200

calcUser gravatar image

I have 2 buttons in my spreadsheet ( libreoffice 6.2.0.3 ), both have identical properties except for the macro they call and their y position. button 1 works perfectly but when i click button 2 it works but then there is a dotted line around the label on the button. If i then click an empty cell the dotted line goes away and the button looks normal again. Why is this happening and how do i fix it?

edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
0

answered 2019-02-08 08:00:08 +0200

calcUser gravatar image

updated 2019-02-08 08:00:39 +0200

Ok, it turns out that you need to go to design mode and then Right click on the Button and select Control, then under the General Tab set 'Tab Stop' to No and set 'Take Focus on Click' to No, I did this for both buttons and now they operate as I expected them to

I installed the Object Inspector but after messing around with it some I decided I really did not know how to use it, so I will remove it

edit flag offensive delete link more

Comments

-0- Your question primarily was "Why?". There wasn't actually something to "fix", but to change in a way better matching your expectations.
-1- The above is mainly a comment on an answer. It's doubtable if it is well placed as an answer.
-2- It's good practice to help users to evaluate answers by either "accepting" one or by up- or downvote them.
-3- The term 'Object inspector' as I used it did not refer to an installable tool. What I wanted to talk of was the additional window titled Properties: Push Button that opens if you click the icon Control if previously a control was selected. (If not shown: Enabel View>Toolbars> Form Controls.) Sorry for unclear terminology.
-4- What "Object inspector" did you mess around with?
-5- How did you "go to design mode" without previously having selected the control?
-6- To have controls being members of ...(more)

Lupp gravatar imageLupp ( 2019-02-08 10:42:39 +0200 )edit
0

answered 2019-02-08 00:39:57 +0200

Lupp gravatar image

updated 2019-02-08 00:42:01 +0200

The dotted rectangle shows that the button has the focus.
You may generally trigger the action by clicking on it, but if it has the focus, the event 'Execute action' will also be raised by pressing the Enter key.
By default the last clicked button takes the focus. You can prohibit this for a control under 'General' in the object inspector.
If you click into a cell, the cell takes the focus. ...

edit flag offensive delete link more

Comments

Why does Button 1 work fine but Button 2 act differently? Also, how do i start the Object Inspector? I cant find it on any of the menu's (did I overlook it?)

calcUser gravatar imagecalcUser ( 2019-02-08 07:31:53 +0200 )edit

Since I don't know how you had set the related properties, I only can guess you clicked "button 2" last. If both the buttons are enabled and have default behaviour concerning the focus, the one clicked last will have the focus (if not user code called by it already changed this). Did you try to click "button 1" a second time? What happened?
Concerning the term "object inspector" you find my answer in the other comment under -3-.

Lupp gravatar imageLupp ( 2019-02-08 10:52:26 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2019-02-07 23:43:51 +0200

Seen: 31 times

Last updated: Feb 08