On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.
Sub Import_worksheet() Dim customerBook As Workbook Dim filter As String Dim caption As String Dim customerFilename As String Dim customerWorkbook As Workbook Dim targetWorkbook As Workbook ' active workbook is the target Set targetWorkbook = Application.ActiveWorkbook ' get the customer workbook filter = "Excel files (*.xlsx),*.xlsx" 'The open dialog is to point to the following path as a constant: C:\MyFile\Data caption = "Please Select an input file " customerFilename = Application.GetOpenFilename(filter, , caption) If customerFilename = False Then MsgBox "No File specified.", vbExclamation, "ERROR" Exit Sub Else 'Filter should be only xls and xlsx files ' If Cancel is pressed then abort the whole macro Set customerWorkbook = Application.Workbooks.Open(customerFilename) .......
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
|Why would a IF THEN result jump up to a prior line in the VBA code||12||50|
|Bulk update/recode of survey text responses to numerical values via a lookup table using macros||8||38|
|Command button to lock and unlock sheet to protect formulas in Excel||6||27|
|Excel + % to Goal when number is negative||21||24|