global

  1. S

    runtime error '1004': method 'range' of object '_global' failed

    Hi there, thanks for looking. I have a simple bit of code that I would like to loop through each column and then graph this. I have my dates in column A and then B, C, D..... etc are full of numbers. I would like them individually graphed into new sheets. I have written this code but for some...
  2. S

    Can I share a Public Const across multiple workbooks?

    Hey gang, I've run into an issue which would be easily solved with a #include of a .H file in C, but which I can't figure out how to do in VBA. Here's what I have. Script.XLSM Microsoft Excel Objects Sheet1 -> Contains a key macro to be copied into the Output.XLSM file on Sheet1...
  3. M

    VBA: Global eNum / Variables or Constants?

    Dear all The workbook I am working with is set to be used with userforms only; there are around 20 of them. I have a number of variables of type byte which are repeatedly used in userforms. Is it a good idea to create global variables, global constants or enum whose values are set when the...
  4. A

    Declaring a variable as a global constant question

    Hi All, I've declared the below variable as follows:- Global Const FilePathName As String = "X:\Sales\Tools\Available Distribution Tool\Company" I've tried to replace multiple file paths with the above along with the rest of the file path, but when you step through the code it doesn't seem to...
  5. E

    Passing Global Variables by Value

    I want to create public variables, but always want to pass the current value of the variable from one procedure to another. For Example: ------------------- Option Explicit Public X as Long Public Y as Long Public Z as Long Sub A () X = 1 Y= 2 Z = X + Y Call B Worksheets...
  6. B

    VBA- Global Databases?

    Hi, I am trying to make a global macro that involves inputting VLOOKUP formulas into cells. The problem is that the data being looked up has to be pasted into a workbook that already has the data tables that need to be referenced. My question is if/how I can make global data ranges that a global...
  7. gemcgraw

    Making a Variable Global

    I am toggling command buttons (enable/disable) based on a variable's value from the same or another spread sheet. I believe I need to make those variables globle in order for the statement to correctly see it. I'm not sure if that is my issue or not and how I can effectively do that. I am...
  8. A

    Assigning Value to Global variable

    Hi, I'm new to excel VBA. Hope someone can help me. I am assigning value to a textbox inside a subroutine. There are 16 such scenarios. Now I want to add up all base and all Pand I values and store them in a different textbox. I was thinking of using a global variable but I've been unable to do...
  9. J

    Declare and set project variables for worksheets and dynamic ranges

    Hi I am trying to declare and set worksheet and dynamic range variables globally. I have several worksheets and forms in a workbook and I have found it difficult to keep track of where all my variables are stored so that when I make any amendments to the location of the worksheet or range, they...
  10. S

    Global Static and dynamic variable possible?

    Hi all, i need a variable for a date which is static, global, and the value of this variable can be changed via a userform. Is that possible?? :| Excel 2003 Shie Boon Thanks
  11. H

    Global replacement of Comment's User name in workbook

    I've changed 'the user's name', but that is only prospective (going forward). Do I have to get into VBA, or what is recommended to change ALL user names. (The "replace" command doesn't do it either). Any thoughts? Thanks!
  12. S

    Declaring a global variable for a string in Excel or VB

    If I have cause to populate a cell by referencing another cell in another worksheet is it possible to shorten the reference by declaring a global variable with a string value which will replace the common part of the re-occurring reference? For instance if I have references in two separate cells...
  13. F

    Can't get global VBA macro to work globally

    I'm trying to use a VBA macro to prefill the save dialogue box with the date, anytime ANY workbook is saved. The code (pasted below) is only working for the workbook containing the VBA code. I've tried inserting the code into my Personal Macro Workbook, and also saving and loading it as an...
  14. A

    Make cell style for all workbooks

    I made a few cell styles pretty easily that I planned to use for all of my spreadsheets. How can you have a cell style show up in the cell style dialog box in all spreadsheets, not just the ones that have that style? I see that you can paste in a group of cells with those styles, but I'd like...
  15. J

    local v global names, and data validation by list

    Hi. I have a globally defined named range called "Year" that refers to =Rates!$B$3:$X$3 In a worksheet "Model (1)" I have a B1 cell on which the data validation is set to "Pick from list", and that list is defined as =Year So far so good. I believe that this would not have worked had the...

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