I have searched high and low and cannot seem to find an answer. I have inserted an ActiveX button in a cell to run 3 macros when pressed. I cannot get the 4-letter name on the button to appear centered on the button, unless I make the button larger than the cell, which I do not want to do.
I have created an ActiveX command button and the text on the button looks crude. I know that is not very descriptive but I am unsure how to describe it. The text looks jagged and some letters are missing chunks of their letters. The font I have chosen is Calibri.
If I create a Form Controls button I do not have this problem but I want the button to have a particular background color so I do not believe I can use a Form Controls button.
I do not know why the other Calibri text on the worksheet looks fine while the ActiveX Calibri text does not. The attached image shows the two buttons with the top one being the ActiveX button while the bottom is a Forms button.
Is there a way in VBA to reference the activeX button which has been clicked? Like a ThisWorkbook equivalent for a button?
I have quite a few button whereby they set a parameter for a procedure 'TrendData' based on the row they sit in. Currently I just have the row number hard coded i.e. Call TrendData(5) but I want to amend this so that when I add a row it doesn't offset all my buttons.
For Example
Call TrendData(CommandButton3.TopLeftCell.Row)
However instead of typing CommandButton3, CommandButton4, etc. I would like the code to know which button had been clicked and just use that?
I have created several macros where i use an active-X control button. This button is pressed and the macro begins...........but every now and again this button changes size for no apparent reason.
I have read countless articles/posts about what "may" be causing the problem but i have never read anything which clearly identifies the soln to this problem and the problem has been out there for years. To make matters worse the problem can not be duplicated on any regular frequency that i am aware of............so its not like i can post a file that will show the problem.............
I am creating a status board at work... Kinda like an In/out board.
I created a toggle button and using it as the persons named. I want them to be able to go to the excel sheet on our intranet. Be able to click their name (toggle button) and it change the off cell from red to white and the on cell from white to green. Then they can save the excel sheet and close out for the next person.
edit: I would also need it to go back once they click it when they leave.
I have created the active x button, but so far the only thing I can do is get the 1 cell it effects to say true/false.
I have made an excel workbook detailing team performance that all of my team have access to and that requires updating once a day. The first person to access the workbook each day presses a Command Button that updates the workbook and inserts a time/date stamp. However, other members of the team go into the workbook and update it again the same day which then affects the data being reported.
I know i should probably just sack them for not being able to read the time and date but HR would not like that so is there a way to disable CommandButton1 (ActiveX) so that once it is pressed it is disables until the next day?
I am putting several buttons into my spread sheet and would prefer to use ActiveX controls rather than form controls. But I also need to hide the buttons from the end user (controls are to update data and will be used by the person who maintains the workbook). When I go to hide the columns, the ActiveX button doesn't hide with it. On the other hand, if I use a Form Control Button instead, it does indeed disappear when I hide the columns. Is there any way to get the ActiveX button to hide when hiding the columns?
I am using the following code to copy a template to a new worksheet each month:
Code: Sub CopyTemplateNewMonth() Application.ScreenUpdating = False Dim SourceRange As Range, DestRange As Range
[Code]....
Everything copies over except an Activex Control button. I also have form control buttons with macros assigned to them, and they copy & paste just fine. The code assigned to the ActiveX button also copy's & paste's just fine...but the button itself does not.
Can Active-X control button macro be placed in a regular module, or does it always have to reside in the sheet module? Or is the only way to accomplish this is to have the macro in the regular module being called from the button macro in the sheet module?
I somehow seem to remember a way to move/assign an Active-X ControlButton macro to a regular module, but maybe I'm wrong?
I would like to know the easiest way to temporarily keep a worksheet code from running while I am editing, then turn it back on when I am done. I was thinking a button with these commands(?)>
Application.ScreenUpdating = False
Application.EnableEvents = True
but I don't know which button to use, or if I would need a button for each.
I have a workbook with two worksheets, "Main" and "Control".
Both of them are with hidden tabs (unchecked "show sheet tabs").
On worksheet "Main" I have command button which opens worksheet "Control".
The assigned makro is: Sheets("Control").Select
The problem is: when I open "Control" and close after that the workbook, the next time when I open the workbook "Control" pops-up instead of "Main" even though I do not save it.
1. I need macro on "Main" which will allow me to open "Control".
2. Regardless I "Save" or "Don't Save" "Control" when selected and workbook is closed, to open the workbook always displaying worksheet "Main".
Every time I copy and paste a small object "jpg" or "png" into a cell it defauts in the cell to the left and top edge s of the cell. I would like the object to be centered in the cell. I can drag the object to "Close to Center", but I have green and red go/no go dots in 120 cell going downward I would would really like to see them aligned.
I have a basic data table with KPI labels down one side and dates across the top. Using this data table as the series source, I create a number of charts below it with serialised names eg Chart0, Chart1, Chart2, etc. I am attempting to enable the KPI labels so that when a user clicks it, the spreadsheet will navigate to the appropriate chart. I place the name value for the chart object in the cell immediataly to the left of each KPI label (and hide it). This way I know which chart object below is related to which KPI label above. That part works. I have a Worksheet_SelectionChange() event procedure attached to the charting worksheet. When a user clicks into one of the KPI labels, the event procedure fires and the appropriate chart is activated. The code is:
Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Not Intersect(Target, Range("B5:B19")) Is Nothing Then On Error Resume Next chtObjName = Range(Target.Address).Offset(0, -1).Range("A1").Value If Left(chtObjName, 5) = "Chart" Then ActiveSheet.ChartObjects(chtObjName).Select If Err.Number <> 0 Then MsgBox "No such chart exists.", vbCritical, _ "Chart Not Found" End If End If On Error Goto 0 End If End Sub
I'm building an application that uses a large number of activex combo boxes. These boxes are getting loaded from specific fields in an associated database.
I know ActiveX combo boxes can be buggy; I'm wondering if anyone has found a way around the text appearance inconsistencies seen in these controls? e.g., sometimes the text is smaller, sometimes it's spaced wider, sometimes it appears at the top of the combo box sometimes in the center.
I put a screen shot of what I'm talking about in a word doc along with a control properties screen shot, All controls have the same properties except for the text property.
is there a way of changing the text direction for an ActiveX textbox? I need it to show the text in some of the boxes vertically but in other boxes horizontal.
I'm having trouble keeping the formatting correctly in a text box through VBA. I'm sure this is something simple, but I'm the intern that got stuck with trying to program for the break since they know I've taken classes on the subject. I've been able to figure out a lot
End goal: To have the first word of a text box larger, underlined, and bolded. Problem: It only formats it Calibri at 24 point with no special formatting as indicated in the code.
adjust the following code so that my images are just a bit lower than "top aligned"? The code centers my images perfectly within the cells, but when you top align an image, it's just a hair too high and border formatting does not come out.
In A1 there is an ActiveX Control Text Box inserted, now in A1 cell which is beneath this text box contain the formula that if A9 is blank than "Customer Name" should appear else it should show blank. But the problem is when I write some thing in this text box which is connected with A9, formula works as "Customer Name" disappears but when I delete in text box it simply acts as if something is still present in cell A9 and formula does not comeback to "Customer Name" again & therefore in order to appear "Customer Name" I have to go to A9 and press delete button to get the desirous result from the formula.
Readers are requested to make this formula work becz the situation in which this formula has been invented is well fitted and not other formula can supplant it.
If the user selects French (radio button selection), I want to swap out the existing English text for French and vice versa. One large text box with several paragraphs. Can Excel do this?
Msg = "Enter a number" BOXTITLE = "Number" ANS = InputBox(Msg, BOXTITLE)
This generates 2 buttons. If i click the cancel button how would i direct the code to go to a certain line in my code. EG if cancel button clicked then goto 10
I have about 20 buttons on an excel worksheet. Is there a line of code that will tell me the text which was one was selected? The reason I am asking is because what is being passed into a module depends on what is selected. I know I can do a Case statement or if statements saying if this selected then this, if this selected then this, etc but was hoping for a one liner. This way it will be easy to maitain if other buttons are added as well.
Was thinking it is something like this but not sure how to say which button is selected. strButtonName = Selection.Text
Is there a way to change the text on a toggle button in the code below? Basically I would like for the toggle button to begin with the word "START" on it and then when clicked changed to the word "STOP". Of course then when the user clicks on "STOP" it changes back to "START".