msgbox

  1. K

    Insert and Center Image

    Hello all, I am new to coding VBA and I am stuck on two aspects of the code. I am trying to insert an image under data that is on the excel sheet(the image is coming from a file on my computer), automatically delete the previous image without deleting a logo that is on the worksheet, and...
  2. K

    how to keep from exiting sub with this code?

    For Each nP In Range(Cells(1, 14), Cells(cntRowsN, 14)) ' E-H-S INCIDENT TALLY ' COPY THE ROWS IN THE "EHS" COLUMN (ON THE ANALYTICS SHEET) AND PASTE ONTO THE TOTAL COLUMN (A2) ON THE "REPORTS" WORKSHEET: If cntRowsN >= 1 Then 'copies just the rows in column F and pastes them on the...
  3. P

    How to tab to a specific control automatically once an option button inside a frame is selected

    Inside a userform, I have a frame and a textbox. Inside the frame I have six option buttons. When the form initializes none of the option buttons are selected but as soon as the user selects any of the option buttons I need it to tab to the next control (textbox1). Is there not an easier way to...
  4. R

    MsgBox to open a form on pdf

    I would like a macro in which a MsgBox selection would open a pdf form in acrobat. Such as ack yes/No, selecting yes would open would then open document as well as another function I already have operating. Any help would be greatly appreciated.
  5. B

    Piovt Table Sorting

    I use the macro below to sort a Pivot table descending based on the value cell I have selected in Pivot Table value section, regardless of how many Row Labels there are. It works for a standard Pivot Table, but not one that has been added to the Data Model. Any ideas as to what needs to be...
  6. I

    MsgBox Yes / No to make cell interior Hot Pink

    Afternoon, I have in use the following code which transfers data from my userform to my worksheet. Before i see the message "Customer Postage Sheet Updated" i am looking for a Yes / No Msgbox. Where if No is selected then continue to show the "Customer Postage Sheet Updated" as normal BUT If...
  7. B

    for loop using variable

    I am trying to use a variable to determine how many times to go thru a loop. The code that I am trying to get to work is shown below. If I use 'For S1 = 1 to 2", I go inside my loop 2 times. If I use 'For S1 = 1 to NumofTimes', I do not get inside my loop. The Msgboxes show a value of 1 and a...
  8. VBE313

    Co-worker doesn’t know how to save

    My co-workers computer turned off due to a power outage and lost his file he was working on for hours and didn’t save. Is there an application code that can do create an if statement like If Application has been open for 20 minutes, msgbox “Save!!”
  9. K

    Macro MsgBox issue

    Hi Everyone, I have quick question :) How can i add MsgBox if there is no "fail" current week ? Is it possible to help me to finish this macro ? Thank you Sub GetFilterForFails() ' ' GetFilterForFails Macro ' ' Dim CurrentYear As Integer Dim previousweek As Integer Dim slaUK As...
  10. S

    Is there any way to check whether an option button has been checked?

    I'm trying to create a form where, if certain fields are blank, it prevents the user from printing I got most of the code to work, but I can't manage to figure out how to check whether an option button has been selected. A lot of resources I've found say to use something along the lines of If...
  11. G

    VBA code - Overwriting contents of row

    Hi, need help. I have a command button to paste the data to sheet 2 but it's just overwriting the data to row 2. Codes as follows: Sub Add_Entry() Dim historyWks As Worksheet Dim inputWks As Worksheet Dim Derick As Worksheet Dim nextRow As Long Dim oCol As Long...
  12. M

    Save all sheets to PDF

    Hi, Looking for VBA to save all sheets to PDF. Currently i have the below, but only saves the active sheet. Thanks. Private Sub CommandButton8_Click() Dim sPath As String Dim sFile As Variant Dim ws As Workbook On Error GoTo ErrHandle sPath = ThisWorkbook.Path & "\" &...
  13. A

    OnKey with Msgbox

    How can I create a msgbox with Onkey code below. I want to create a message that says this function is restricted. Application.OnKey "^n", "^n"
  14. R

    MsgBox if Range as date has passed

    I am sure this has been answered before, therefore I apologize in advance. Can someone please assist me in a macro code under Worksheet_calculate to simply write. If Range("N9") < Now() And Range("O9").value = False then MsgBox "xxx xxx" End If It seems simple yet I can not come up with it...
  15. A

    Excel VBA Autofilter field as a variable

    I am trying to develop a code that will autofilter a field, that will change month to month. I have a userform where the user selects the reporting month, then the script finds that month across the top of a structured table, and then drops down 1 row to select the header of the structured...
  16. C

    RE: Displaying a Msgbox 1 hour after the workbook opens

    RE: Displaying a Msgbox 1 hour after the workbook opens This code is in the Workbook Open() event: Private Sub Workbook_Open() If Day(Now) = 10 Then MsgBox "Good morning" else End if This works great but displays the MsgBox as soon as soon the workbook is opened. How do I get the MsgBox...
  17. F

    Define Range using VBA

    Good Day I have the following which writes to a specific cell. I would like to extend the range for column H Thanks Sub Meet() If ThisWorkbook.Sheets(1).Range("H15:H15").Value = "" Then MsgBox "Please Enter a Meeting Number" Exit Sub End If End Sub
  18. C

    Display a Msgbox when workbook opens on a specific day specified from Userform data...

    I tried to explain as simple and completely in this title. I have this and it is hard coded in the vb Workbook Open event code window If Day(Now) = 8 Then MsgBox "See if anyone on MrExcel can help" Else End if All this does is display a predefined Msgbox text string on a predefined day...
  19. kelly mort

    Printer name and tray selection with vba code

    I have been on the web for a while now looking for solutions to my problems. I came a bit closer yet I am stacked trying to complete the next steps: Private Declare Function CreateIC Lib "gdi32" Alias "CreateICA" _ (ByVal lpDriverName As String, ByVal lpDeviceName As...

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