myvar1

  1. J

    Best way to declare variables for use in all modules?

    Hi, As title, I'm unsure of the correct way to do this as I've seen a few ways. On workbook open ? Public / Const? Example: myVar1 = Sheets("Sheet1").Range("A1").value How can I use myVar1 in all macros without any further declaration Any info appreciated
  2. J

    Pass variable from Private Sub Worksheet_SelectionChange to a Module ?

    Hi, having trouble figuring this out, i have the following sheet code: Private Sub Worksheet_SelectionChange(ByVal Target As Range) If Not Intersect(Target, Range("Z2:Z50")) Is Nothing Then If Target.Offset(0, 1).Value = Target.Offset(0, 2).Value Then 'do...
  3. kelly mort

    Multiple InputBox Then Split Result Into Cells

    Hello, I came up with this code and I am stacked here as to what I wanna achieve. I need 8 variables; what I have here is just two of those. They are assigned by the inputbox, then after that send them to my worksheet by breaking the input into two where the comma appears in the user input...
  4. T

    Object variable or With block variable not set

    Standard module: Dim MyVar(1 To 10, 1 To 10) As MyClass Set MyVar(1 To 10, 1 To 10) = New MyClass MyVar(1, 1).Category = "Some category" MyVar(2, 1).Fruit = "Some fruit" MyClass: Private pCategory As Variant Private pFruit As Variant Public Property Get Category() As Variant...

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