Can I skip/disable a sub code before run my marco then recover it like as following:
Private Sub progress()
Skip run/disable Sub Worksheet_Change(ByVal Target As Range)
My Marco
Recover/enable Sub Worksheet_Change(ByVal Target As Range)
End Sub
First off, I just started to really learn vba, so I'm clueless to some of this stuff but I do know how to research and learn.
Now, I have a worksheet that I to automatically input data into cells when specific columns are changed.
I've been working and searching for hours and I have had no...
Hey all,
A little background on my vba project: When the date in a cell is a past date, the cell style changes to "Bad".
I am trying to code this logic: If you change a past date to today's or a future date, then change a cell in another column, but same row, to the style "Neutral". For some...
I have a list of existing worksheet names in A1:A50 (although the worksheets themselves are NOT in that order) and a list of new names I want to update each sheet to in B1:B50. I would like to run a macro that looks for the worksheet name in A1, finds it in the workbook and then renames it to B1...
Recently got promoted at my job to start and manage inventory. We have a set up excel sheet but currently have to manually update inventory when a product leaves. To keep it short for example product one uses 5 screws, 2 nuts, and one hinge. How would I make it so that if I enter that we sold 5...
Hello all,
I have this code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, [H16]) Is Nothing Then
If [H16] < -9.99 Then
[I1].EntireColumn.Hidden = False
Else: [I1].EntireColumn.Hidden = True
End If
End If
End Sub
It works perfectly, but I...
Hello all,
I am trying to do a worksheet change code, but can't quite get it right.
Private Sub Worksheet_Change(ByVal Target As Range) If H16 < -10 Then
Columns("I:I").Hidden = False
End If
End Sub
What I am trying to do is, when the value of H16 is changed, and it is less...
Hi,
Need help I am new pretty new to VBA, created a worksheet it is working for 1 condition but I tried a lot but unable to make it work for the second condition in the same worksheet.
Background: The first code pasted below calls the I need to below code to call a macro when the condition1...
Hi all,
I have two worksheet changes that I am having trouble to combine so that the changes work at the same time. The two changes do affect the same cells, but one hides the whole row and one stops specific cells from being deleted.
Here are the two codes:
Private Sub Worksheet_Change(ByVal...
I have the following macros set up in one worksheet "code-behind" page to call other macros when specific cells are changed:
---------------------------------------------------
Private Sub worksheet_change(ByVal Target As Range)
If Not Intersect(Target, Me.Range("B9")) Is Nothing Then Call...
Hello all,
I'm not sure if this is possible to do, but I figured I'd ask around and maybe someone smarter than I will have a creative solution.
I have a worksheet change event that highlights the current row that is selected. See below:
Option ExplicitConst MyAreas =...
Hello all,
I have been able to customize the right click menu on various cells in my workbook, but I was wondering if it were possible to customize the right click menu that appears when you click on any page tab. Is this possible?
Any help would be greatly appreciated. I'll attach the code...
Hi there
I have a simple code that hides rows when either W or S is selected in a cell ("H19"). I want the code to disable after a selection is made so the application.goto does not activate every time i populate a cell, however code should be activated again when the cell ("H19") contents is...
Hello, need help with combining these 2 worksheet change events. Tried combining both under 1 worksheet change, didn't work. Anyways, here's the code. Please help, what's wrong?
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
Dim MyRange As Range
Dim c As Range
Dim MyRange2 As Range...
hi there
I am trying to create a vba worksheet change code to do the following:
Once a cell Sheet1(a1) is populated with a quantity (drop down list 1-10), rows 1-3 on sheet 2 are to be copied and inserted on Sheet1 row 2 repeated by the cell value.
When a cell Sheet1(b1) is populated with a...
Hello,
I am trying to automatically move an entire row of data to a different sheet based on changing text in a certain column i.e. entering "YES" in column I. I am new to writing code. The code I wrote seems to be skipping some steps. Can anyone help?
Private Sub Worksheet_Change(ByVal Target...
Hello guys and gals,
I'm a rookie to VBA and currently trying to combine two separate worksheet changes to my excel sheet. Both work individually, but i haven't found a way to combine them to run. I want them to change certain cells to N/A, dependent on the data in other cells. I know the codes...
I have a lot of appreciation for all the experts on here, so I was wondering if any one would be able to come up with a solution for the question/problem below:
Sheet 'TABLE' has a range named LUTable which is populated with data. I have also applied a range name for each column:
Col A=...
Hi, Just looking for some help with this one. When the user clicks a cell, then the active cell is within the range of Column list in the Code below then it will open the a user form however at the moment when you click on any cell not in the list it opens the user form. If you take the NOT Out...
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.