commandbutton1_click

  1. kelly mort

    Randomly run one out of three macros

    Hello , I am looking at three separate macros right now. Say : macro1 macro2 macro3 . Below is the button to call Private Sub CommandButton1_Click 'Inside here I want to choose one of those macros at random End Sub How will I run just one of those three at random?
  2. J

    VBA code to attach a Single file to different Cells on Multiple Sheets

    Hi all, I am a complete novice with VBA but I am loving the learning curve. I have been searching for ever for a solution to my post but I have been unable to find one. At the moment I have put together the code below that works but the issue with it is that you need to keep selecting the folder...
  3. M

    For...Next Statement vba

    I'm using MS Office 2010. win7 Somehow I've gotten the selected new rows to focus rather than the most recent one. I need to use FOR Loop to find and select only the last row. so how would i put it in For...Next Statementthis what i have so far: Option Explicit Private Sub...
  4. gheyman

    List of Tab Names

    How do I get this to but the list starting in A3? Private Sub CommandButton1_Click() Dim i As Integer For i = 1 To ThisWorkbook.Sheets.Count Sheets(3).Cells(i, 1) = Sheets(i).Name Next i End Sub
  5. S

    Cant get Thisworkbook.activate to work

    Any idea why this code wont return to the original workbook? Private Sub CommandButton1_Click() Selection.Offset(1, 0).Select Selection.Copy Workbooks("PromoVendorTemplate.xlsx").Activate ActiveSheet.Paste Destination:=Worksheets("Sheet1").Range("a2") ThisWorkbook.Sheets("April").Activate End...
  6. P

    Call command buttons from userform

    Hi can anyone help? I am using a userform and have added a Command button within the form and I want it to call CommandButton1 on Sheet2 that in turn calls other CommandButtons for other sheets. Is this possible? I get a compile error saying 'Sub or function not defined' and highlights 'Call...
  7. F

    vba CommandButton.1

    Here is my code to create a clickable button. ActiveSheet.OLEObjects.Add(ClassType:="Forms.CommandButton.1", Link:=False _ , DisplayAsIcon:=False, Left:=96.7, Top:=341.25, Width:=100, Height:= _ 55).Select ActiveSheet.OLEObjects(1).Object.Caption = "YES"...
  8. M

    Help finishing simple VBA

    Looking to return staterate and localrate from xml response to cells A1 and A2 in active WS I will modify later so that street address, city, and zip can be in three other cells in the sheet so the commandbutton1 can query for tax rate when clicked. This is what I have so far: Private Sub...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top