Do Not Show A Macro's Steps
Jul 15, 2009
I have written a macro, big cheers as it's my first, and it even works as I wanted it to.
Trouble is when you run it, it shows you all the steps it is making. Is there any way to stop this and purely for the end result to appear? It may well also have something to do with my PC needing more RAM to make it faster. Ever since upgrading (?) to 2007, my PC feels like it is stuck in quicksand.
View 5 Replies
ADVERTISEMENT
Feb 21, 2010
Need advice/opinions of where to go 1st to learn all about VBA/Macro's from a novice point of view.
View 3 Replies
View Related
Jan 15, 2009
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.1"
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.2"
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.3"
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.4"
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.5"
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.6"
etc . . .
Basically, I just recorded a macro to change the cell value. This code continues to 4.8 . . .Is there a more efficient way to code this??
Also, I'd like to add a time delay (say +-5seconds) between each step. So basically it would say:
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.1"
[CODE THAT DELAYS FOR A TIME, THEN GOES TO THE STEP BELOW]
Range("A1").Select
ActiveCell.FormulaR1C1 = "3.2"
[CODE THAT DELAYS FOR A TIME, THEN GOES TO THE STEP BELOW]
View 4 Replies
View Related
Apr 8, 2009
I have an excel spreadsheet that I am trying to format. Each time the spreadsheet is of the same format but with differing amount of numbers. I.e. sometimes it will be a set of 3, the next time might be 6.
I want to write a macro that will find a set piece of text, move it offset(-1,2) and then find the next one.
For example....
View 14 Replies
View Related
Jan 25, 2013
I am looking for a macro that works like the ASAP Utility (Transpose data from one column to several columns in steps). To elaborate the work done by the macro it should transpose the values in a column to the number of steps that is user defined (Using InputBox) that is if there are 103 values in the column and the user enters the number of steps as 24 then the macro should transpose the data up to 24 columns and the rest in the next row up to 24 columns and so on unless the complete data is transposed.
For more clarity refer the attached excel sheet or the "Transpose data from one column to several columns in steps" utility of ASAP Utility.
View 3 Replies
View Related
Jun 9, 2014
How to plot a step graph?
I have attached a drawing by illustrating the graph that I wish to plot.
Attached Image : jpg Capture.JPG
View 9 Replies
View Related
Sep 17, 2007
I am trying to produce a list of numbers (preferred Sheets Function and not VBA).
Every group should be of 5 Identical Numbers - starting with 2 and step of 2.
(An Example is shown in the attached picture).
I would like to produce that list with the help of ROW() and all available build-in Functions.
If possible, I will appreciate very much some explanation as for the principal of producing such a list when, for inatance, the step is 3 , starting from 3, while every group includes only 4 identical numbers and the first cell, to present the first value, is A11 and down to A26 - presented here in Horizontal layout:
(3,3,3,3,6,6,6,6,9,9,9,9,12,12,12,12)
View 3 Replies
View Related
Oct 15, 2009
I have 2 columns of data with 7,000 rows that I am trying to manipulate in the following way. The first column contains a list of car manufacturers (not really my example, but involves the same concept). The second column contains a list of different models of cars. For instance,
Ford | Taurus
Chevrolet | Avalanche
Saturn | Sky
Ford | Explorer
Honda | Accord
Ford | Taurus
What I want is a list of 2 columns with UNIQUE car manufacturers in first column with a list of UNIQUE car models (comma delimited) in second column. So for this example, the first row could read " Ford | Taurus,Explorer". I don't want Taurus to appear twice. I got a lot of help from JBeaucaire from this post. I just can't add the ability to remove car models from the list also. Thanks in advance for all the help!
View 7 Replies
View Related
Aug 15, 2014
I have the onerous task of dividing up a series of steps in one cell into multiple cells. I tried the text to columns utility, but it only delimits once, not multiple times. Below is a data example:
"1) Load App
2) Login using Administrator Access details .
3) Click on icon 'Admin' on the right hand side of page.
4) click on subcategory 'Administration'"
"1) Load App
2) Login using Administrator Access details .
3) Click on icon 'Admin' on the right hand side of page.
4) Click on subcategory 'Administration' .
5) Click on any Organization name from 'Organization' section in the list.
Or click on 'Add Organization' icon in section 'Organization' .
6) Validate field 'Parent Organization' in 'New Organization' or 'Edit Organization' form"
"1) Load Documoto.
2) Login using Administrator Access details .
3) Click on icon 'Admin' on the right hand side of page.
4) Click on subcategory 'Administration' .
5) Click on any Organization name from 'Organization' section in the list.
Or click on 'Add Organization' icon in section 'Organization' .
6) Validate field 'Tenant ERP Accessible' in 'New Organization' or 'Edit Organization' form"
1) Load App
2) Login using Administrator Access details .
3) Click on icon 'Admin' on the right hand side of page.
4) Click on subcategory 'Administration' .
5) Click on any Organization name from 'Organization' section in the list.
Or click on 'Add Organization' icon in section 'Organization' .
6) Validate field 'DMZ license key expiration period ' by click on checkbox or by 'Uncheck' checkbox"
I need to put each step into it's own cell.
View 1 Replies
View Related
May 19, 2014
I have a project with over 600 steps which we are trying to track when each part progresses by having 52 weekly columns. Their are 8 users which we have allocated a colour so when they complete one of the steps they select which step they have completed and which colour they are. This works well but I would like to put the date that the change was made in a separate cell in that row.
My question is can this be done with a formula as I am in favour of doing this as soon as someone changes a cell in the week range. If not I will need to nut through a VBA sub routine.
I know that this formaul does not work but it is along the lines of what I am testing for: =if(sum(T55:BM55)>" ",Date(),0) where if any of the cells in the range T55 to BM55 have any value or letter in them then put todays date in cell L55 else do nothing.
View 1 Replies
View Related
Oct 16, 2009
I am trying to make a save&close workbook macro.
I found several examples on google, but unfortunatly it conflicts with another macro I use for forceing users to enable macros (hide all sheets except one if macros are disabled).
The attached file is an example contaning the save&close code and the show/hide sheets depending on macros enabled.
If the file is opened with macros disabled then only one sheet will be visible.
If the file is opened with macros enabled other sheets are visible.
The problem if that this code uses a custom save, witch makes the save&close not save... (in module1 and in ThisWorkbook)
The pourpose of the save&close is to make sure some users don't forget the excel open and thus block access to it. So if a certain idele time passes excel has to save and close without any confirmation messages.
View 10 Replies
View Related
Oct 25, 2008
As i have a pretty "complex" macro, which takes around 20-30 minutes to do (honestly)....
I was wondering if there was a way to create a progress bar just showing me how many % it has done so for?
Or even tell me which sub routine it is up to? (but % would probably be better)
And preferably a pop-up box one?.. not one on the status bar because i have stuff updated on the status bar already...
View 14 Replies
View Related
Nov 25, 2009
I have a workbook that I constantly am improving with new macros and VB routines. I sometimes have two versions available for use at the same time. I would like to create a macro or routine that will tell me if the workbook has been saved. A simple cell color change to indicate I've saved would be fine. Also, if I DO save the file and the cell color changes to indicate I have saved, I would like the cell color to change back if any change is made to the workbook. This way I will always know if I need to save or not to keep latest changes.
View 3 Replies
View Related
Dec 3, 2011
I have a userform that shows while a macro is running. The userform just informs the user that the macro is still in progress. However, I can get the userform to show and the macro to run, but the label on the userform won't appear. Here is the code I have:
Code:
Private Sub Userform_Activate()
Application.ScreenUpdating = False
Sheets("Data").Select
[Code].....
View 1 Replies
View Related
Dec 3, 2012
Any way using a macro so that a chart will not show the "0" columns?
View 6 Replies
View Related
Jul 9, 2007
I have a macro which downloads data from website. But takes some more time to complete a work. I want that a time should display at the bottom bar of excel where "Ready" is written. THe time should be in hh.mm.ss format.
View 9 Replies
View Related
Jul 2, 2009
I'm trying to create a macro that will hide all the rows where the value in column E is equal to zero.
I'm currently using rows 1:700, but I may add to it.
View 9 Replies
View Related
Nov 19, 2009
I have looked through alot of this board and see the codes to hide all tabs old and new and code for each sheet.
My question is:
Is there a macro that can be used to do this as well. Say a button to hide all tabs and a button to show all tabs or does it only hide/show when the workbook is re-opened?
View 9 Replies
View Related
Aug 20, 2008
Recently I found this forum through a Google search along with the perfect solution to a problem I was having finding and replacing text based on a table of replacement values. Here is the thread:
Multiple substitute or replace text using a table
I incorporated the SuperSub function that steveorg developed as a result of that thread into my worksheet by creating a new module and pasting the following code into it:
Function SuperSub(OriginalText As String, rngOldText As Range)
Dim cel As Range
Dim strOldText As String, strNewText As String
' loop through list of old_text used in substitute
For Each cel In rngOldText.Cells
strOldText = cel.Value
strNewText = cel.Offset(0, 1).Value
OriginalText = Application.WorksheetFunction.Substitute(OriginalText, strOldText, strNewText)
Next cel
SuperSub = OriginalText
End Function
It works like a charm as a formula, but I also have a macro in the same workbook that, as soon as it selects the sheet with the formula, calls the SuperSub function and starts executing the code as a macro (even though there is no call to this routine in the macro). The macro ran just fine before incorporating the function into my worksheet.
The formula looks like this: =TRIM((supersub( UPPER(E2),rngSubst)))
If cell E2 contains the string "101 North Main Street, Apartment 5", it would return "101 N MAIN ST APT 5"
Here is the macro:
Sub Import()
'
Sheets("Shoebuy FTP").Select
Range("A2:R200").ClearContents 'This is where it jumps to Function SuperSub(OriginalText As String, rngOldText As Range)
The function runs for every occurrence of the formula in the worksheet, and when it is finished, all of the cells containing that formula show a value of "#VALUE!". I should mention that it does not change the formula at all, but I then have to highlight each cell that contains the formula, press <F2> to edit, then <ENTER> to get it to display the correct results again.
It is probably some stupid little thing that I didn't do when I created the function, but I can't figure it out. I have written numerous macros, but this is the first time I have ever created a custom function.
View 5 Replies
View Related
Nov 29, 2006
I got a code that makes an animated userform popup (web browser in userform). that works smoothly. but, when I have that code before two more codes. The userform does show, but the animation does not. Until all the following two codes are finished running. The purpose was to have the animation running while the two codes are being processed.
Main Code: Code with 3 different codes.
Private Sub cmdAdd_Click()
Dim iRow As Long
If Sheets("LookupLists"). Range("N2").Value = "EXACT" Then
Application. ScreenUpdating = False
' Loading user form popup
Call ShowFrm
Call CopyEmplInfo
End If
Call MergeCells
End Sub
View 5 Replies
View Related
Dec 14, 2006
I have selected 6 rows and 2 columns in a sheet and I have a button in the same sheet.Now I click the button it triggers the button_click where I have put msgbox to popup.But I need this selected value in message box instead of the my hard coded string.
sample value in the selected cell:
1,1.005
2, 3.006
.........
..........
View 3 Replies
View Related
Jul 24, 2007
I have a standard laid out spreadsheet, but in column C, D and E, there are comments in each cell which are filled with a lot of text. I would like to set a macro so that whenever an 'a' is in column A, the comments for that row are shown/hidden (the 'a' being a tick symbol in Webdings). So if I place an 'a' in A4 and A23, and click a show/hide button, it causes the comments in C4, D4, E4; C23, D23 and E23 to be displayed, and when it is clicked again (or it could be a separate button), they disappear. If no row has an 'a' in the A column, then the button has no action. I have recorded a Macro of me showing and hiding comments, but of course that is for a specific row.
View 6 Replies
View Related
Dec 15, 2007
I have a simple macro that I have been using to hide columns in a very large spreadsheet. Essentially, the user has access to buttons that allow him to choose between a variety of the most commonly used views. For some reason, when I add columns and adjust the code to hide/reveal these columns, I get:
"Run-time error '1004' - Unable to set the Hidden property of the range class"
with the Debugger highlighting the code for "BO:DC". This problem occurs for several of the similar buttons, including toggle buttons, that hide/reveal columns. I am aware that custom views can be created in the drop-down menu, but I wanted to keep these buttons on the sheet as a quick means of moving from view to view and toggling columns between hidden and revealed.
Private Sub CBMonographMLA_Click() ...
View 3 Replies
View Related
Nov 19, 2007
as an example i will use the national lottery. numbers 1 to 49 inclusive. i need a formula that will list all the possibile 6 number combinations not repeating any.
View 6 Replies
View Related
Apr 25, 2014
macro which can show a picture of a certain cell and if I change the value of that cell the picture will be changed to the new cell value,
Like
If I put in cell A1 value DOG, so the pic in cell B1 is a dog pic that I defined before, and if I change that value to a cat, the pic should be changed to another pic.
View 1 Replies
View Related
Oct 29, 2008
I got a quite huge excel file with multiple sheets. For convenience sake I want to group and hide all the sheets not necessary for the viewer.
View 14 Replies
View Related
Feb 22, 2013
I am trying to to create a macro that will complete a Pivot Table, then use the Show All pages function. The data has the same number of columns each time, but the rows will differ each and everytime. The content of the column which houses the data which eventually will be a page can differ as well. I continue to get an errro and below is highlighted when debug is selected.
ActiveWorkbook.PivotCaches.Create(SourceType:=xlDatabase, SourceData:= _
"Table1", Version:=xlPivotTableVersion12).CreatePivotTable TableDestination _
:="Sheet4!R3C1", TableName:="PivotTable2", DefaultVersion:= _
xlPivotTableVersion12
This is a very repititive pivot that is done many times during a month. I have tried just using the data as is then the pivot, and converting the data into a table, doesn't matter still get the error.
View 7 Replies
View Related
Dec 9, 2008
I have recorded the below macro to select a pivot table field (on demand) and show the information on anthother sheet tab.
Obviously if the order of the fields change then the macro is buggered, any ideas so it only selects the on demand field and shows that info.
Sub Macro1() ....
View 9 Replies
View Related
May 11, 2006
I have a sheet that the is preset with the autofiter on. The sheet is protective. I have the following code as a marco and all works fine but if alldata is not already showing. If all of the data is showing and I run the marco, I get and error. What do I need so if all the data is already showing, one will not get an error?
Also from my code the marco is set to only run in one sheet or if the user is another sheet will the marco run?? I am guessing that the marco will run in any active sheet. If that is so what would I need to change to have the macro run in only one name sheet, for example sheet named "Frog"?
Sub AllData()
'
' AllData Macro
' Shows All Data
'
' Keyboard Shortcut: Ctrl+a
'
ActiveSheet.Unprotect Password:="pword"
Worksheets("Diag List").ShowAllData
ActiveSheet.Protect Password:="pword"
View 5 Replies
View Related
May 3, 2008
I have a modal userform that I load to warn the user that the system is busy processing a scheduled job. The form is nothing more than a screen that comes up and says "One moment please..." with the form caption set to "Processing...". When I use the form in this way, if I don't use an application.wait command the form just shows the header without the text that it shows when I look at in the in the VBA IDE. (In other words it is just blank.)
View 4 Replies
View Related