I currently have a macro that takes a user selected name and date and creates a time sheet for the selected name. This works just fine, however i have to select each individual person and run the macro for each person, how to automate that part of the macro, so it will automatically create the said sheet for all person at once, rather than me doing it manually.
[Code] .....
The 'CurrentMonth' variable is user selected from a list, and will remain that way.
i'm writing a refrigeration selection user interface, working from values on an excel spreadsheet. how to get the programme to automatically select a value from a list or range once a user has selected corresponding value from a list within a combobox. for example if a user sets the temperature of their refrigerator to -5 celsius i need the programme to automatically select the corresponding value of enthalpy for the air at that temperature.
I have a workbook that has three worksheets. The ASU Database sheet contains part numbers and descriptions including specific details that are selected from pull down data validation lists that are named on the third worksheet. I want to have a front end on the first worksheet that has similar data validation lists for the user to select from to create a search criteria that will create a worksheet with only the rows that meet this criteria. I am not sure what method to use to accomplish this.
I have a form that asks at what row the user wants to start with a selected range then how many rows to select. There will always be 21 columns selected with this range. I am still learning but it has to do with something on how I am setting the Start object. It is not being recognized.
Dim Row As Long Dim Selection As Long Dim Start As Range
how you would write a macro to move a selection of sheets to a workbook called Digi's in the D drive. Also if there isn't a Workbook called Digi's already it needs to add one. I've found some code to loop through sheets but nothing to show what sheets the user has selected
I would like the user to select two files, the macro then inputs a formula that includes vlookup to the other sheet. However i am not sure how to reference each workbook.
Sub InsertLocationContents()
Dim rng As Range Dim LastRow As Long
'OPEN CSV FILE WITH LOCATION CONTENTS
csvFN = Application. GetOpenFilename(Title:="Select Location Contents csv file") If csvFN = False Then ' They pressed Cancel MsgBox "Stopping because you did not select a file" Exit Sub Else Workbooks.Open Filename:=csvFN Workbooks.OpenText Filename:= _ csvFN, Origin:=437 _ .............................
I am using this code to copy columns C,D, and P from a user selected workbook into position C,D,E of workbook "Checklist.xlsx" (the one from were I run the VBA code). I don't have a clue about VBA, just have been gathering info, but the code works pretty fine. The only issue is that it opens twice the workbook "wbExt" hence the system prompts me if i want to reopen the already open workbook.
Some questions:
1) Is there a way to copy the 3 columns at once? something like "Columns("C:D, P").Select". 2) Is there a way to select the workbook from were to copy the column without needing it to actually open? 3) is there a way to paste the columns starting from row 3 instead of row 1 (Range("C1").Select)?
Within a worksheet, I have several radio buttons, allowing the user to select only one of them. Using VBA, how do I recognize which radio button the user selected?
On the first row of a spreadsheet template is a <hidden> contiguous series of conditionally formatted cells (range name "stdRow" =production!$1:$1), with formulas, that I want a user to be able to easily insert at whatever row they might be in a worksheet.
If, for example, the user is at D24, then clicks the [InsertRow] button that I have positioned at the top of the worksheet (in a fixed pane), I want the attached macro to insert an instance of "stdRow" directly underneath the user position (at row 25, in this case). The use's position should still be at D24 when the macro finishes. If the user clicks the button multiple times, multiple rows should be inserted (again, without changing the user's position).
The User has made multiple selections with the mouse. The spreadsheet is filtered. The user will usually make different multiple selections on the following columns: A and X through to AR (inclusive).
I just need some code to capture these various multiple selected ranges so that I can copy the selected range as shown below:
I want to do a concatenate for multiple fields, but want the user to specify which cells should be concatenated by entering this in a few fields. What does this formula (or VBA) look like?
Let's assume there is the possibility to concatenate a maximum of 4 cells. Call the 3 cells that will be concatenated cell1, cell2, cell3 and cell4.
On the first sheet of the workbook the user enters the following: cell1 = Sheet2!A4 cell2 = Sheet2!B4 cell3 = Sheet2!C4 cell4 = Sheet2!D4
Here are some cells and their values: Sheet2!A4 = Hel Sheet2!B4 = lo Sheet2!C4 = World Sheet2!D4 =
Upon enterring the information after the = sign for the cell1, cell2 and cell3, the formula for the concatenate becomes: =CONCATENATE(Sheet2!A4, Sheet2!B4,Sheet2!C4 ).
The result of the formula is: HelloWorld
If I now change the values of cell1, cell2, cell3, and cell4 the following should happen: cell1 = Sheet2!B4 cell2 = Sheet2!C4 cell3 = cell4 =
The formula for the concatenate becomes: =CONCATENATE(Sheet2!B4, Sheet2!C4).
I'm trying to create a macro that allows users to hide or unhide selected rows, either via toggle or userform. The macro I have looks like this, but for some reason it doesn't hide the rows:
Sub Hide_Range() Dim UserRange As Range DefaultRange = Selection.Address Set UserRange = Application.InputBox _ (Prompt:="Select Range to Hide:", _ Title:="Hide Range", _ Default:=DefaultRange, _ Type:=8) Rows.Select Selection.EntireRow.Hidden = True End Sub
what's wrong with my code and how I can further develop it to let the user decide whether to hide or unhide the selected rows?
I am trying to display number of lines which depends on value pass by user. Actually user is passing some value. on which some group of lines has to be display.
eg for 1 value 9 lines for 2 value first 9 lines + another 9 lines for 3 value first 18lines + 9 lines and so on till 52.(this 9 lines are set of some column and rows)
I am trying to write this macro so that I can optimize 181 outputs based on 2 inputs (columns A and B are inputs). Each row has a single output at the end of the row that I am trying to minimize. I want to be able to select as many of the rows that I want and have the code optimize each individual row. So far I can't get it to let me use variable cell references for the "ByChange:="$A$3,$B$3"." This is the hang up that is not letting me increment the macro to the next row. The macro works currently for the single selected cell, but until I can vary the ByChange portion, I can't automate it.
Have a person Input an Assembly Number and,Have Excel return a list of Part Numbers, their Descriptions, and a Quantity for each Part Number that will need to be packaged with the Assembly Number that was Input.
The output needs to be in the form of a check sheet (I can play with the formatting if I can get the information out) for the one Assembly Number input.The output can either be in a separate spreadsheet or a User Form. The spreadsheet is easier for me to work with but the User Form looks cooler.
I can use a VBA Function to Input the Assembly Number but then I need some way of searching a small table (about 20x20 cells) to find the matching Assembly Number and then return the Part Numbers, etc. to a check sheet so the parts can be packaged. Each Assembly Number can have several Part Numbers associated with it. Either unique to that Assembly Number or common to other Assembly Numbers. The Quantities can also be unique or common. A couple of simple examples might be:
I have a macro that works perfectly to import a text file and parse it. Now i need it to do multiple ones. I import the txt file to a new workbook as i filter for certain data only and if found i copy that to the current workbook. I want to do the same just for many txt files:
I'm trying to use data validation to restrict the user to only selecting values in a list which I create. Right now, the list is a named range. I'd like to get rid of the range and just use a named list. I create a name using the following as my list.
Insert > Name > Create Name: Fruit
Refers to: banana,apple,orange
When I try to use the name Fruit in my data validation, I get the message "The List Source must be a delimited list, or a reference to single row or column." I thought my name "fruit" was a delimited list.
I am creating a userform in Excel 2007 which requires a user to pick their name from a drop down box then press Ok, what i want to do is disable the Ok button until the user field has been selected.
I wrote a macro which creates desired output based on one default variables. But I want to change it to take user selected assumptions and perform the macro for each user selected variables.
I am confused with user forms and controls and what to use.
Can anyone give the code to how to add a list box to a userform and then add items to the listbox, and run macro based on thegiven input in the list box?
I'm trying to create a drop down list which returns values based on what has been selected in the previous drop down list in the adjacent cell, e.g. if 'Apples' is selected in the previous cell then you should only be able to select from 'Gala, Granny Smith', or if 'Oranges' is selected you should only be able to select 'Seville, Blood Orange'. Is there a formula which would do this, or can I use a pivot table somehow? I'm totally stumped.
I need to have a drop down list which displays a different set of values depending upon the value selected by a previous drop down list. ie. (drop down box 1)= x, y, z. (drop down box 2)= either x1, x2, x3, or y1, y2, y3, or z1, z2, z3. I can produce a single drop down box thats not a problem but linking several drop down boxes is beyond me .
I am trying to do is to make it so that users can enter data into my form (I have managed to create the form and am working on trying to figure out how to get the info entered into the form to appear in my worksheet) and then the data will cause the information to, basically, compile sentences that I want to appear in one of three cells at the bottom of the worksheet.
Essentially, at this point in time, the end goal is to make 3 cells that contain text. Eventually, this text will be indexed elsewhere, but that is for the next person to deal with. I am creating a prototype that I want to present as a process improvement.
So, when the user selects 3 in cell D7 I want the text "Customer purchased 3 Widgets at $20 each." to print in cell 82B. I also want the user to be able to copy and paste some customer records from another program directly into a cell in the form that will just print (unchanged) into one of these boxes, too.
Lastly, I want the user to be able to select checkboxes that will, when selected, print a comment that will print in two of these boxes. For example, if the user selects yes for cell D26 then I want the text "Customer not eligible for free shipping" to appear in both cells C82 and D82.
My requirement is to implement a drop down list having two values "Yes (Recommended), No", I want the value "Yes (Recommended)" to be default value for all cells on which this validation is put. But also need a message box to be displayed if the user go ahead and select "No" the message box should be like "If you are not certain about this feature please click on 'Cancel' and contact you List Provider." and have 'Ok' and 'Cancel' button on it.
=IF(A2="","",IF(INDEX('JOBNAME Time Cards'!K:K,(ROWS($1:1)-1)*7+1)="No TV","","X"))
The idea is basically, if on another page at specific cells there is a value of 'No TV', there will be an empty cell - otherwise there will be an X.
In the past this has worked fine, but now that I've changed the way the 'No TV' cell works to be a dropdown of options, it no longer works. Even though 'No TV' is selected from the dropdown, the value is still X.
"I have 2 listboxes 1st listbox is listing all macros in sheet user can select macro which he intend to run and transfer them into another listbox once he have selected all macros he want to run just press commanad but to run it will pick all macros from listbox 2 and strat running them one by one"
In sheet1 i have a Listbox(Controlbox), which stores data of 100 names. Now in the D column i need to type the Name. So i would like to have a code which can pull the list box below the Cell I am Typing and it has to match the strings i type to list box(i.e, Pull data from the Listbox as i type the character in a cell)
So here i need 2 Modules 1- Which will pull the data from the listbox 2 - which will bring the list box below any cell which i am typing
The below is causing me an issue as it is setting the ws value to equal nothing instead of sheet1 or sheet2 etc. I have my dimensions set above and there are no spelling mistakes.
It falls down on the VB : Set LastRow = ws.Range("a65536").End(xlUp) line but this seems to happen because ws is set to nothing.
VB: For iramp2 = 0 To ListBox1.ListCount - 1 If ListBox1.Selected(iramp2) Then Set ws = ActiveWorkbook.Sheets("Sheet" & iramp2) End If