target.address

  1. C

    Compile error - Procedure too large. Code assistance needed.

    Assistance needed to break this Code down to a smaller version as I am getting a Compile Error - Procedure too large. Current Code: Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = "$BA$4" Then Shapes("A 1").Width = Target.Value * Range("BA157") End If If...
  2. H

    New to Macros Help with Range apply to whole column/row not one cell

    Hi I'm working on a simple worksheet with 6 columns: A = Buy Price (pre populated) B = Sell Price (To be input by User or Calculated) C = Amount (pre populated) D = Buy Value ( A * C ) E = Sell Value (To be input by User or Calculated) F = Pecentage (To be input by User or Calculated) Basically...
  3. S

    EXCEL VBA: COMPILE ERROR: Procedure too large - repetitive Selection change

    I'm using VBA for EXCEL. I'm also new to using it and this board. All I'm trying to accomplish is that when a user inputs his/her initials in cell D5 the current time plus 1 hour will be inputted in C5. I do this repetitively until cells o62 and P62. I have repeated my code below to do...
  4. A

    Efficient worksheet change vba code

    Hi all Does anybody no a way to perform the actions of the following code more efficiently / with less lines of code. As is, I will need to run similar versions of it over 500 times (Will this cause a speed issue?). Each version of the code will look for a different word (72 in total) in cell...
  5. S

    Worksheet Change Problem

    I'm sure there is an easy solution to this, but I can't figure it out. I am trying to create a form in Excel that has multiple drop down lists and I would like to have a macro that will replace some cell values with "N/A" is no is selected from the drop down. I can get it to work on this...
  6. V

    Worksheet_Change (adding two target addresses into one VBA code

    Hello, I am trying to have a Worksheet_Change that will run a VBA code. Right now I have the first part done. What this code does is that it works with a Drop-down list in Cell V6 and when someone selects this drop-down list it will run a code called Do_it_1 and also change a commandbutton...
  7. P

    VB Sheet Protect while allowing only font color changes.

    I have VB code running to allow multiple items to be selected from a drop down. The VB code also unlocks and locks the sheet before and after. However, users have the need to proof read the text that others submit and I require that they make deletions in red text and additions in blue text...
  8. L

    Filtering 0 VBA

    I'm trying to filter 0s and I did it for one table, but when I try to execute it for a second table it only leaves the 0s Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = Range("AreaLead").Address Then Sheets("TOCalc").Range("$A$1:$E$34").AutoFilter Field:=5...
  9. R

    why does this only work on the worksheet_change event?

    Greetings, I am using this code on a worksheet to change the fill color on a shape dependent on the value in one of the cells. It works great and so I would like to use the same technique in a different WB; but I want to assign it to a command button instead. But I keep getting an error code...
  10. I

    VBA-dropdown list influencing shape location

    I have this code that creates text boxes on worsheet(1) when I enter something in Worksheet(1) A1 to A30. At the moment the boxes are created on top of each other. Now I want to add a new feature: I want the place of the texboxes to be choosen acoordingly, when I choose one option of a...
  11. P

    VBA Novice, need help breaking code into smaller pieces

    I am a true beginner with editing code, but I have a workbook that has many repeating formulas and I got to a point when building the file that it no longer works. In trying to resolve the issue, what I am assuming is that I need to break up the following code into smaller pieces...
  12. B

    VBA Worksheet_Change Help!

    Hi - I've been playing around for over an hour and keep getting different errors! How can I get this code to exit sub if Target.Address = "D3" Is Blank? My Code; Private Sub Worksheet_Change(ByVal Target As Range) If Target.Address = "$D$3" Is Nothing Then Exit Sub Else...
  13. A

    Would like Target.Address to only run from one module

    Hello, I have several modules housing different code. Each Code runs in the same Range Area. I have one module that gives a place to put a value in J5. And from there is uses Worksheet_Change to run a separate Module. I've added the "If Target.address section" after a Select Case setup. This...
  14. T

    How can I edit this sort so it work when a set of cells is clicked not just1?

    Hi Everyone The code below works great, what it does is when I click on cell AJ101 it sorts my data using AJ as the sort column. Now I want to be able to do this with all the headers in the range, so when I click AC101 it sort by AC ect using the same rules as I currently use. So how can I...
  15. S

    SheetChange script throws Run Time error when clearing any cell

    I'm novice by all definitions with VBA, but I can usually piece things together that I need to do. this one is stumping me. I have a cell, C62, that I have a data validation list with five options. Two options out of that, I want it to make additional rows, 65-68, visible. The code works...
  16. countryfan_nt

    run time error 424: object required

    Hello friends, Hope all is well! Stuck in the below code, I got run time error 424: object required. The following was highlighted: If Target.Address = "$I$5" Then Really and always appreciate your help in advance! Private Sub Worksheet_SelectionChange(ByVal Target As Range) Call CHANGE...
  17. R

    Select Case Target.Address for range of cells

    Hi I have a working code to make a calendar pop up when ever someone selects a specific cell. However I would like to make it work for whenever a cell in a range is selected ("G2:G3000 "I2:I3000" "J2:J3000 "L2:L3000") or anywhere in column G, I, J, and L. The code I have at the moment will...
  18. B

    Using Worksheet_Change for two Different Target.Address (Excel 2007)

    Greetings. I have two cells that are both drop down lists referenced from a Vlookup Table. When One cell is "D11" for the "Group" and the other is "D12" for the "Campaign". When the user selects from the drop down cell what they want, I have 3 pivot tables that should change their filter based...
  19. Prevost

    Adding character in front of changed cell value on change

    Hi There. I want the character "#" to be added in front of a cell value when a value is entered. I have this code but it is a worksheet_sheet change event and I am not sure if that is the correct way to go about it. Thanks! Private Sub Worksheet_Change(ByVal Target As Range) Dim...
  20. B

    Linking 2 cells so that changing either cell changes the other cell

    I have two cells on different worksheets and I want to be able to link one cell to the other so that changing either cell will change the other as well. Or, alternatively, each cell links to a third cell that changes whenever either of the other two cells is changed. I have no experience with...

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