Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. CWalsh87

    Sorting Pivottable by vba not working

    Here's an example _______________FZ7442____|___FZ7448___|___FZ7456__| _____________|_13/04/12__|__12/04/12__|__13/04/12_| Part Number__| 12345________|__100______|_____100____|____100____| The FZ numbers are the order numbers. It should be sorting like...
  2. CWalsh87

    Sorting Pivottable by vba not working

    Hi, I'm using the following code to sort a pivottable: Me.subfrmDeliveries.Form.PivotTable.ActiveView.FieldSets("Prom Date").Fields("Prom Date").SortDirection = plSortDirectionAscending I'm happy the code is correct, but the pivottable is not sorting correctly, it's sorting by the "PO...
  3. CWalsh87

    Adding Recordset to array then filter pivottable based on array

    Figured it out!! I changed the field type from Number to Text in my table and that resolved the problem. I don't know why that sorted it but it did :) Thanks again for your help! Chris
  4. CWalsh87

    Adding Recordset to array then filter pivottable based on array

    Thanks, i've tries the above and i get the same error, I'm starting to think the code is correct but there's a problem somewhere in Access Any suggestions really appreciated. Cheers Chris
  5. CWalsh87

    Adding Recordset to array then filter pivottable based on array

    Thanks for the reply. I've tried the above and it just crashes access. It "encounters a problem and needs to close" The error is: AppName: msaccess.exe AppVer: 10.0.6771.0 ModName: oleaut32.dll ModVer: 5.1.2600.6058 Offset: 00004c27 Any ideas? Cheers Chris
  6. CWalsh87

    Adding Recordset to array then filter pivottable based on array

    To make it a bit clearer: This works: Me.subfrmDeliveries.Form.PivotTable.ActiveView.RowAxis.FieldSets(1).Fields(0).IncludedMembers = Array("5113","5112") but the code in the first post doesn't. I need to just get the data from the table into the array and this should work? Any ideas...
  7. CWalsh87

    Adding Recordset to array then filter pivottable based on array

    Afternoon, Apologies I have posted this in another section of the forum, but was advised to move it, i'm not trying to spam! Basically what I am trying to do is enter a value into a listbox (value is stored in a table) add these values into an array, then update a pivot table based on the...
  8. CWalsh87

    Adding listbox to array

    Afternoon, Basically what I am trying to do is enter a value into a listbox (value is stored in a table) add these values into an array, then update a pivot table based on the values in the array. I can add the items to the listbox / table. This works fine. I can filter the pivot table based...
  9. CWalsh87

    Pivot Table: Filter from Array

    Hi, I'm really having problems with this and looked all over for an answer. I have a pivot table in a form, with a list box (based on a table). I want to be able to click a button and the pivot table to be updated based on the values in the listbox. What I have done is create and array from...
  10. CWalsh87

    Excel VBA inserting unwanted quote marks!

    I've narrowed the problem down to the fact that i'm using R1C1 notation. But i still don't know how i can stop the extra ' marks getting inserted
  11. CWalsh87

    Excel VBA inserting unwanted quote marks!

    Hi, I need to insert a function into cells using VBA. For various reasons i need a variable in the function so i've used the following code: For a = 1 to 10 activesheet.range("D1:D100").select Selection.FormulaR1C1 = "=IF(ISERROR(SEARCH('Product Type'!D" & a & ",rc[1],1)),"""",'Product...
  12. CWalsh87

    FormulaR1C1 Help Please

    Thanks Combo, the second part of your post sorted it!!!! (missed your comment!) Really helped me out! Cheers Chris
  13. CWalsh87

    FormulaR1C1 Help Please

    Here's another thing i've found... the value returned in the target cell is always what is in the "if_false" part of the "If" formula. e.g. i've just changed the original code to: Activecell.FormulaR1C1 = "=if(iserror(match(RC[+3],'Product Type'!A:A,0)),""123"",RC[+3])" and "123" is...
  14. CWalsh87

    FormulaR1C1 Help Please

    I've narrowed it down slightly. It has to be something to do with the MATCH() part of the formula. I've deleted the match and put in: activecell.formular1cq "=if(rc[1]=""AD0001"",""Yes"",""No"")" And this returns "Yes" or "No" depending on the target cell value. Any ideas?
  15. CWalsh87

    FormulaR1C1 Help Please

    Thanks for the fast reply. I forgot to mention the calculation setting is on automatic. i've even inserted the xlcaulcationautomatic before the formula is inserted to ensure this. Chris
  16. CWalsh87

    FormulaR1C1 Help Please

    Hi, this is my first post on the forum, although the forums been very helpful over the last few months. I have however searched and cannot find an answer to my question. I have some VBA code which inserts a formula (using FormulaR1C1) into a cell. the problem is, the formaula is getting...

Part and Inventory Search

Back
Top