Permitted Permutation/Combinations With Some Rules
May 25, 2007
I have found this very challenging, and have really confused my self on how to systematically approach this. I have the user enter the value in the black highlight boxes, some subtraction produces a base value, the user may also enter the tolerance of the working value (base value), effectivlly giving rise to a small range to generate the permutations from.
What I would like to do then is find all permutations of the inventory (letters in the sheet) with their corresponding values right above them to the small range determined via the user (working value and tolerance). There are also quantity limits for each item. There four basic rules that need to be adhered to:
1) Permutation can't have both S and PP, so one or the other
2) Sum of H and HN must be greater or equal to sum of S and PP
3) H or HN or both must be present, so their sum cannot be zero
4) If HN is less than or equal to 2, and H is greater than 2, then NA and NG must equal 0.
Can this be done in Excel? Using the digits 0,1,2,3,4,5,6,7,8,9 create all the permutations/combinations with limits on some of the digits. The digits 0,7,8,9 can only be used a max of 3 times in any one permutation/combination, digits 2,3,4,5,6 can only be used 4 time in any one permutaion/combination, producing a 5-digit string. Example of expected results. 0 1 0 2 7
I am using Visual Studio 2005 Profesional with VSTO, making a program for Excel Office 11. My code is working when inside the Studio. But when building the code, and then trying to run the xls file direktly I get the error attached. I need information about what I am doing wrong, and how I can change the .NET security policy so that the code will also run outside the Studio.
Could Not load file Or assembly 'TestExcel, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Failed to grant permission to execute. (Exception from HRESULT: 0x80131418)............................
Copy & paste (ctrl c & ctrl v) is very useful, but it will change the format of the cell. To avoid that it is possible use paste special (value). Is possible to protect the spreadsheet so only paste special (value) is permitted?
I have a worksheet that has headings along the and summary stats down the right and bottom of an area where details can be entered.
Depending on a persons user name columns are hidden/visible so that they can only enter information relevant to their section. The workbook is also shared.
What I want to do is stop people from being able to overwrite the headings or formula that calculate the stats but as the workbook is shared and the VBA that hides/unhides the columns needs the sheet to unprotected I am having to use code to prevent this: ....
This is for an online sports management game I play. Basically I have calculated each players skills in each position, and I need to find the best combination of the players on the field to give me the best team.
I have a table as below, and I need to find a solution that gives me what the best combination will be....
I am trying to create a list of permutations in a column for example I need a list of numbers 1-20 with no numbers repeating. This is causing my head to hurt and I have been working on this problem for some time.
I have been asked if I can create a pseudo Lottery/Bingo card of 7 images with no repeat cards. The best i can tell is that I need to create a Permutation of the numbers 1 - 7. There should be 5040 combinations of unique possible cards. My problem being I don't know how to create this Permutation in Excel.
i have read through all threads about permutation, and also a few others. I if I were an Excel Pro I would probably have been able to come up with a solution to my problem based on all the suggestions made, but unfortunately it is (still) all a bit too complex for me.
The problem:
I have between 2 and 5 lists of words, each list in one column:
Column A
red green yellow black blue green pink
Column B
shirt jumper blouse coat t-shirt skirt
Column C
for women for men for girls extra large for boys one size fits all
I have several items that I would like to combine, lets call them characters A, B, C, D, E
Each character is situated in a different column, next to each other. Below, I would like to create a list of all possible combinations of these characters. The sequence is not important and each row should contain a unique combination of characters.
I have counted 31 combinations for the ABCDE set, namely
1 for ABCDE 5 for A, B, C, D, E each 5 for choosing 5 unique sets of four from a set of five (5!/(4!*(5-4)!) 10 for choosing 10 unique sets of three from a set of five (5!/(3!*(5-3)!) 10 for choosing 10 unique sets of two from a set of five (5!/(2!*(5-2)!)
To complicate matters, I have several other character strings where I would like a list of combinations. For example A, B, C, D, E, F, G, H 9 (a longer set).
By the way, each combination should be spread accross several columns (e.g. one colum per character, see the question marks in the table below) ....
I'm new here, google helped me to find this place. Hope someone here can help me a bit on my excel spreadsheet. I have one list of numbers and it need to be sorted under Perm condition so the list become shorter. The function should go through the listed number and output new list after sorting it. I have attached my excel here.
I am creating a worksheet that I need to encorporate an If statement into. What I need to happen is when cell A1 has a number in it (1,2,3,4...) I need it to perform a function on cells B1 and C1. However there will always be information in cells B1 and C1, but I only need it to perform the function when the number in cell A1 is anything but 0.
How can I create a rule for a table that finds a specified word and replaces it with another such that the rule would continue to apply to the table even when a new record (or row) is added. There has to be a simple way to do this without a macro.
Seems to behave differently each time it is called from my main Loop. As an example the first loop finds: TotalTubes = 6 TubeRows = 4 TopRowTubeCount = 2 Where 6/4 = 1.5 and is rounded up to 2
The controlling variable in my code for Length is TopRowTubeCount and it is a Public Variable Dimensioned as an Integer
However on the next loop it finds: TotalTubes = 210 TubeRows = 4 TopRowTubeCount = 52 Where 210/4 = 52.5 and is rounded down to 52?
I even used the round function for the TopRowTubeCount calculation and the erratic behavior continues.
I have 2 input boxes. Input Box 1 asks for user's Date of Birth. Input Box 2 asks for user's name: Pretty simple right! They will loop until following 2 conditions are met: If the user enters something in them OR user presses Cancel. If they are empty and Ok is pressed then keep on looping.
I have set all cells in a worksheet to be protected. I then selected specific cells that are not protected. The problem is that cells A11:D29 except C13:C14 do not follow the protection rules in that I can edit them (but when I right click, I cannot format, just like they're protected). These cells are NOT part of the group that was selected to be unprotected. When I unprotect the sheet and check the protection setting for these oddball cells, it shows as protected. All other protected cells do not allow entry (which is what I want).
how to display the current set of conditional formatting? I don't want to go to the cells I want a listing of all the conditional formatting rules. I am sure I have seen this somewhere in the past but cannot locate it.
I have two conditional formatting rules that work independently, but I am looking to combine them into 1 rule, making (2) subject to (1) when (1) is true
I have started to use excel again because I need to create a spreadsheet for maintenance hours done on a vessel. The problem I have right now is, how to set a rule to allow only certain multiple of a particular number to appear. For example,
I have a initial cell value where I have to manually insert the total number of hours that have gone by in the vessel. Let us say that this value is 500 hours.
In another cell which is labeled, "Last Completed", it would have to read at how many hours this job was last completed.
I also have another cell which gives you the time interval before the job is performed again. This value is 250.
So if the current number of hours is 500, the last completed date should be 250. (assuming Maintenance was done at 0 hours and 250 hours).
How do I make it so that the "Last Completed" cell would read 250 until I hit 750 hours which at that point should read 500 Hours.
I'm looking for assistance with working out the following formula. I live on an apartment complex in Marbella Spain and we pay Monthly Community Fees of say $100.
We want to calculate a penalty amount for late payers of say 30% of the monthly fee due for non payers? So for instance if the monthly amount due in Cell D8 = 100 and the actual amount received in cell E8 shows 0 or then increase any figure due for the following month in Cell F8 should increase by 30% ($ 130) in the following month. and so on
I use Excel ver 2003. Trust my query is reasonably clear?
I'm trying to do a CONCATENATE function in Excel 2003. The first part of the function (this is working correctly) is a) concatenating 4 cells from a different worksheet (WB_NEW) into one cell and is b) putting a space in between each entry:
What I'm now trying to do is enhance this function to perform with 2 separate concatenation rules i.e. "if one of the cells specified above is blank, concatenate a different set of cells".
I would like to fill some cells with a customer id if this customer is the same as the cell bellow. As my example below.
CUSTOMER idCUSTOMER NAME TYPE 737346 Nikos 81 1154765 Kyriakos 81
1154780 Thanos 81
I would like to fill automatically the empty cell bellow Kyriakos the customer id 1154765 in new column. I want in column "new" to fill with customer id and when the customer id is empty to fill the same customer id as above customer id.
I am trying to clear row with the following rules:
the last cell must not contain 0, if 0 delete entire row. the first cell the the A row should be only three character long, if more delete entire row.
Now I managed to delete the 0 in the last cell and but cannot get the VBA to count the characters in the first row and if more than three, delete the entire row . I know to count the characters in a cell is done by Len(Rng.Value) , but getting the VBA right is alluding me .
the script is here,
Sub Del_rows_with_zero_in_column_of_activecell() Application.ScreenUpdating = False Application.Calculation = xlCalculationManual Const StartRow As Long = 1 'Row to Start looking at Dim StopRow As Long Dim Col As Long
I want something strange but i guess you can do just about anything with excel these days if you ask around.
I want names for the sheets that are contained on a specific excel file that i have to be automatically generated accordingly to the following:
sheetname = runxyy_s=zz%
Where x is the lowercase letter of the word formed on the name of the first sheet of the workbook and yy and zz are values stored on specific cells on the sheet,lets say yy is A1 and zz is H4.