module

  1. F

    Public Variable As String

    It seems that a Public variable declared in one module is available in others as well. But what about assigning the value to the variable in one module to be made available in others. Public InitialPart As String 'Module 1 Sub UserInput() InitialPart = "This is the initial part" End Sub...
  2. apgmin

    Count if

    I need a help with the following: A1 to h1 will have a default value of either 1 or blank ( this indicates the number of attempts the student makes for the exam ) Now in Cell J1 I want the response "module repeated" if any of the values from A1 to H1 is changed from 1 to 2 or 3 or 4 etc...
  3. W

    Assign Module to a column

    I have a formula in a Module that I want to assign to Column H. This formula determines if the training date is past Today() and will either display Not Qualified or Fully Qualified. Column H is dynamic based on the amount of training required for the job selected. I currently have it housed in...
  4. S

    VBA Code much slower in one workbook compared to another

    I wrote a VBA macro to manipulate some data in a tab with a module in my Personal Workbook. Everything works great and fast. Now I'd like distribute this to my team, so I do my normal steps: Create a macro-enabled workbook. This is completely empty. Add a module. Paste the exact code from...
  5. K

    custom dialog box on error

    Sub TryOpenFileOpenFolder() Dim FileNameRef1 As String, FileNameRef2 As String, myPath As String FileNameRef1 = Application.WorksheetFunction.Text(Range("A1"), "General") FileNameRef2 = Application.WorksheetFunction.Text(Range("J1"), "General") myPath =...
  6. G

    Copy "code" from "regular module" of Book1 to "This Workbook module" of Book2

    Hi I am very new in VBA and making it with the help of some friends with limited knowledge on this subject. Expecting any help from forum members to solve this. As a part of my project I have created a code to copy a Hidden sheet "Sheet1" from "Workbook19" to new work book and save it as "New...
  7. H

    help with code within Excel

    I would like to know where I can get help within the VBA module, If I cannot remember some of the VBA code names
  8. S

    Playsound not functioning as expected

    Hello fellow VBAers, I hope someone out there can help me. Recently, I created a small tool/exercise/pedagogical game which works well for me but acts strangely for colleagues. The tool calls a recording (a .wav file) via a Function, the code for which I copied from a forum: Private Declare...
  9. kelly mort

    Standard module, UserForm Module or Class Module? ??

    There are some of the Subs that when I call them from the standard module with my userform, I get errors so I have to place them in the userform module. I have not used the class module before. Can someone point out to me whether I am doing the right thing or not? Regards Kelly
  10. S

    VBA workbook_Open problem

    I am looking for vba to prevent workbook_open from executing in new save as file without changing the original file. I have a template that I open with a workbook_Open module to auto generate a sequential number. I want to save the new file to a different location with a new name but I dont...
  11. C

    How copy module to another module (Both in the personal.xls)?

    Anyone know how to copy a module that is in the personal.xls into another module also in the personal.xls? I have some code i want to take and modify it and make a new version hence the desire to copy code module A (in personal.xls) into a module B in the personal.xls.
  12. B

    Programmatically Add Procedure to Sheet Module

    Hello everyone, I am completely stumped on a solution and looking for some guidance. I have written code that among other things, adds a new sheet to a workbook. The workbook in question has a dropdown via data validation, which requires a worksheet change handler in the sheet module. I have...
  13. P

    Copy Module

    Hello, I am trying to use VBA to Export the Module from a Personal Macro Workbook and Import that file into the Active Workbook. I have seen a few that work when it is workbook to workbook but I cannot get them to work from PMW. I am just needing some help. Thank you :) I didn't put any code...
  14. JenniferMurphy

    Best way to send workbook with UDFs?

    I have some workbooks that friends or family members have asked for. Most of them make use of UDFs that are in my personal add-in module. I don't want to give them the entire add-in module for several reasons. What's the best way to make these workbooks transportable? If I copy the UDFs to a...
  15. S

    placing macro in sheet code vs module code - "Cannot run the macro" error

    I am studying the stop watch example shown on this page and trying to incorporate it into a spreadsheet: https://trumpexcel.com/stopwatch-in-excel/ The demo has 3 key functions: one to start the stopwatch, one to stop it, and one to reset it (NOTE: color formatting code and other unnecessary...
  16. JenniferMurphy

    Module name added to calls to personal add-in module

    I have a personal add-in module that I have used for years. It is called zzz add-ins.xlam and is stored, along with a couple of other add-in modules, here: C:\Documents and Settings\Administrator\Application Data\Microsoft\AddIns It contains dozens of UDFs that I have written over the years and...
  17. M

    apl font in vba module

    Hi, Is it possible to change the font in the vba module? I wanted to see apl thanks
  18. R

    One Radio Button To Trigger Another Radio Button On Different Excel Sheet (Same Workbook)

    Hi All, I have a radio button on sheet1 module 1 called (Sec1No). this is the code : Sub Sec1No MsgBox "blah" End Sub Then I have a radio button on sheet2 module2. Is it possible that when the user clicks on the first radio button sheet 1 to then automatically check the radio button on...
  19. N

    Copy Based on Multiple Cells Matching Across 2 worksheets

    I have a work book with 2 worksheets. 1 Worksheet is my raw data. My Second Worksheet is Essentially a form that gets printed to fill out facility condition indexes for an entire campus. I have everything else on my form completed to include when a row of the raw data gets updated, it will time...
  20. H

    VBA: Public variable not carrying between modules (help!)

    Hi guys, So I have some VBA. I am declaring a public variable as integer in module 1 and lets say for example in module 1 it is declared as a value = 19. Public batch_audit_col As Integer batch_audit_col = Application.Match("BATCH1", Dash.Rows("1:1"), 0) Then module 2 starts and I do not...

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