excel 2010

  1. Johnny Thunder

    Create a Global Counter Variable and Global Limit Variable - VBA

    Hi guys, Working on a niche project today that I don't seem to have found a straight answer for. I have a Bex Analyzer (SAP) query in an Excel file to run a query but I want to trigger a macro at the end of the query refresh/run. I found some code online to figure out when the query is...
  2. P

    Excel 2010 Power Query addin - connection only - unable to load

    Hi all - newbie to PQ here. I searched forum / google but couldn't find anything. I created a calendar table in a blank query & clicked "close & load" several times but it just continues to show "connection only". Any advice welcome on how to get this query to load so that I can set...
  3. Johnny Thunder

    VB Code gets different results with different users? - Anyone seen this before?

    Hi guys, saw something weird today. I wrote code that goes into my network at work and grabs a file from a specified folder for our current month "03 - Mar" and does a copy paste to another report. The issue that I saw today is that if another user runs the file the macro is grabbing the file...
  4. Johnny Thunder

    VBA - Format how code returns value of Named Range - Excel 2010

    Hello All, I am working with a userform and need to have a named range value returned as a format number. Currently my named range ("PrgB") returns the value = 51.515151 I need to have this format as a 2 digit number = 51 but cant seem to get this done. Any help is appreciated! my partial...
  5. Johnny Thunder

    VBA - Creating a Progress Bar While Macro is Running

    Hello all, Working on a new type of code for creating a Userform Progress Bar. Never done anything like this before so bare with me. I found this article on the web as a start to create the userform and bar visually - http://www.excel-easy.com/vba/examples/progress-indicator.html And it was...
  6. Johnny Thunder

    Create Dynamic File Name Using Named Range

    Hello All, I am working on a code and trying to insert a named range into the file name reference but I am getting an error "Constant Expression", not sure what I am doing wrong so maybe someone might spot it. Sub CountFiles() Dim xFolder As String Dim xPath As String Dim xCount...
  7. R

    MonteCarlo Simulation VBA... Help cleaning the code to only a certain WS in this WB

    I have created some VBA to quickly run a monte carlo simulation of forecast errors to create prediction intervals for my forecasts. The VBA is simply 1000 iterations of simulated forecast errors. Question: What is the best way to ensure the VBA will run only on WS "MonteCarlo" in this workbook...
  8. Johnny Thunder

    VBA Help - Properly Exit Sub

    Hi Group, Working on a script that is doing a copy/paste type function and looping down a list of text to update a report. I have the code working fine, but when I come across a blank cell I would like the macro to EXIT SUb, the problem that I am having is that I have code after the Exit sub...
  9. D

    Text to Value Summation

    Here is what i am trying to do….is there one formula that would work? In J2, I want to sum L2:R2 where the value of any text in each cell is = to ‘1’ and S2:V2 where the value of any text in each cell is = to ‘.6’. A blank cell would have no value. For example, If L2, M2, and N2 had the words...
  10. Johnny Thunder

    VBA Question - Deselect after Paste - Excel 2010

    Hi guys, Stuck on a problem with my code, I am creating a new sheet and then doing a copy paste function to get the data onto my newly created workbook/Sheet but for some reasons I can't deselect the pasted cells. Maybe someone can see a problem or a solution for my issue. My code: With...
  11. Johnny Thunder

    VBA Help - Setup where to insert Page break - Excel 2010

    Hi guys, Stuck on a code and can't seem to get it to work, hoping someone has come across this in the past or knows how to do this. I have a Set Print Area script that loops thru sheet in a newly added workbook and sets print area and some formatting and I added a line that inserts a page...
  12. Johnny Thunder

    VBA Help - Dynamically Update Named Range to Lastrow

    Hi Guys, working on a script to dynamically update a named range for my data to the last row when a report is ran and hitting a roadblock with my code. I am getting an error on the code, most likely because the syntax is wrong so I was hoping someone may know how to do this. I am using the...
  13. J

    Build and Add To an Array

    Hello everyone, Patience with the newbie please. I've been able to find lot's of VBA help here over the years, and am completely stumped with my new task and need help. I have a model, powered by VBA, that runs multiple iterations. Each iteration results in an output like: (the 9 data cells...
  14. D

    Looping a worksheet change event

    Hello all Im ok at writing some simple code in vba but when it comes to looping the code I always screw it up! I have a code that is working and doing what I want it to do, except I have to re write this for 10000 cells! which is extremely time consuming, as you will see I have shown the exact...
  15. P

    Querying a single cell from multiple workbooks

    I have a large number of workbooks all created from the same template file. They are all formatted in an identical manner, and each worksheet has a timestamp in cell A4 that I'm interested in extracting. I'm trying to consolidate the filename and timestamp (cell ref A4) from each worksheet...
  16. M

    Calculate remaining time of macro with average

    Hello everyone, I have a macro which can run a long time. I have build in code to estimate the time remaining. I did it like this: Dim StartTime As DoubleDim SecondsElapsed As Double RemainingTestcases = Range("TotalTestCases").Value 'Code within while loop: 'Determine how many seconds code...
  17. Johnny Thunder

    Update to Existing Code to Search for File Extension .xls or .xlsm

    Hi guys, working on updating a workbook that contains some code that was inserted into a UserForm. I am having an issue because the code looks in a specific folder with both .xls and .xlsm file and the usual "*.xls*" wildcard doesn't seem to be working? I have tried both "*xl*" and "*xls*"...
  18. Johnny Thunder

    VB Code not being consistent - Excel 2010 - Search Function

    Hi Guys, Was hoping someone could look over my code and see if I am doing something weird to cause an issue with my search Function. My code is looking on a data sheet and searching for text I have entered in a named range CYEAR & " " & Rperiod2 = "2018 Budget" For some reason the search...
  19. Johnny Thunder

    Help with 1 vba formula - Not Working

    Having an issue with a formula in VBA. I am also confused as too why additional quotation marks are needed when using formulas in VBA code? Line: .Range("L4:L" & LR).Formula = _ "=$D$9 & " " & $D$8&" " &FCSTNAME& " " vs. "&$D$9 & " " & $D$8&" " &VERPRIORDESC"
  20. M

    Stop code execution but keep form open

    Hi Everyone, I have a UserForm where a user can check some check boxes and fill in some field. I have one inputfield where the users enters a number, when the user enters 0, I want a msgbox displayed, and when the user hits "ok" I wan't the form to be still open, but the code to stop executing...

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