• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Search results

  1. M

    Create cell A1 as a hyper link to file referenced in Cell A2

    Hi, In Cell A1 have a ProductName, Cell B1 I link to another file to pull in the version number. I'd like to make the ProductName a hyperlink to the file referenced in cell B1. e.g. A1 = ProductA A2 = "V2" from file ='C:\document\[ProductA - V2.xlsm]Version'!$E$3 I'd like to be able to...
  2. M

    VBA to open file referenced in a cell

    That resolved both issues - cheers Luke...you never fail me ;)
  3. M

    VBA to open file referenced in a cell

    This print all files no problem, but also copies them to C:\Users\paulmclaughlin\Documents Meaning all the links have also changed to this folder. Can this be stopped?
  4. M

    VBA to sort by first character of cell

    Cheers guys. Went for the helper column as there would be 6 different possibilities. Thanks again
  5. M

    VBA to open file referenced in a cell

    Luke, works a treat thanks. One more thing. It doesn't close the file after printing it. At the minute I have commented outthe following line as not needed yet, not sure if that make a difference newBook.Worksheets("Prices").PrintOut If possible, I'd like to close it without saving (and...
  6. M

    VBA to sort by first character of cell

    Was kind of hoping you wouldn't say that. It would take a lot work to add another column without messing up a lot other (older) formulas. Thanks
  7. M

    VBA to sort by first character of cell

    for example 2 Bed - 04.........£699 2 Bed - 07.........£599 I want to show as: 2 Bed - 07.........£599 2 Bed - 04.........£699 So sort by the 2 then by the price, ignoring the 04 & 07. Cheers
  8. M

    VBA to open file referenced in a cell

    One for you Luke, from old forum that I could find on here. This worked a treat. How's this look? Sub PrintBooks() Dim c As Range Dim myPath As String Dim newBook As Workbook Application.ScreenUpdating = False For Each c In Range("A1:A23") myPath = c.Formula 'Remove first bracket...
  9. M

    VBA to sort by first character of cell

    Hi, I've created a macro to sort by two columns. This first column i'd just like to order by the first character which is a number, then by the second column. Any ideas would be great. Thanks ActiveWorkbook.Worksheets("FleetChanges").Sort.SortFields.Add Key:=Range( _ "F8:F35")...
  10. M

    VB to delete columns with value in specifc cell [SOLVED]

    Sorted with this (made a few tweaks to the yes/no helper column). Thanks for replying. Dim i For i = 5 To 33 If Sheets("Sheet1").Cells(7, i) = "No" Then Sheets("Sheet1").Range(Cells(7, i), Cells(7, i)).EntireColumn.Delete i = i - 1 End If Next
  11. M

    VB to delete columns with value in specifc cell [SOLVED]

    Neither work. I'm nearly here with this. But after it deletes the column, i need it to step back a column, as if there is two columns together it skips one. Dim Rng As Range Dim Cell As Range Set Rng = Sheets("Sheet1").Range("F7:aZ7") For Each Cell In Rng If Cell = "No"...
  12. M

    VB to delete columns with value in specifc cell [SOLVED]

    Hi, thanks for the response. Didn't work, deleted my first few columns. I need to start checking from cell F7. It also didn't delete the remaining columns that weren't ="yes" thanks
  13. M

    VB to delete columns with value in specifc cell [SOLVED]

    I'm nearly there with it, if someone can help me over the line that would be great. It starts to delete the columns, but then stops and "mismatch error" highlighting If Not Cell = "Yes" Then Dim Rng As Range Dim Cell As Range Set Rng = Sheets("Sheet1").Range("$F$7:$AG$7")...
  14. M

    VB to delete columns with value in specifc cell [SOLVED]

    Hi, Hope you can help. Looking to create a simple script to select columns E:AF and then delete any columns that do not have "Yes" in row 7 of that column. e.g. Column G, cell G7=Yes, so don't delete it. H7=0 therefore delete it. Thanks in advance
  15. M

    VB to open file referenced in a cell

    Hi, I have a cell that links to another file showing a a version number, in cell A1, as below: ='C:Foldersub folder[File1.xlsm]Prices'!$A$1 I also have 23 more of these linking to different files. I want to write a bit of VB to open the File1.xlsm and print the Prices sheet, plus a...
  16. M

    VB, refreshing data in hidden sheet

    Hi Lohith, I used to do it that way, until I learned this new way which is a little slicker. It works fine on another file. And refreshing the query manually works. A bit of anomaly. Cheers anyway
  17. M

    VB, refreshing data in hidden sheet

    also, runtime error 1004 if that helps
  18. M

    VB, refreshing data in hidden sheet

    Hi all, Hopefully a simple one to resolve. I have a hidden sheet, SearchData12, and I am using the following to update the date. ActiveWorkbook.Worksheets("SearchData12").Range("C11").QueryTable.Refresh BackgroundQuery:=False I use it in exactly the same way in another file and if...
  19. M

    Using excel data for parameters in a sql script

    Thanks for getting back to me, I'll be looking at this at some point today.
  20. M

    Using excel data for parameters in a sql script

    Hey, I was wonder if it is possible to have a macro retrieve data from a sql database using some parameters in a workbook, basic example. Cell A1 has customerID, if I enter 123 and run a macro can it select customer 123 from a database to show name is cell B1 Thanks Paul
  21. M

    Counting number of bookings where revenue between set values

    Hi, I'm looking to count the number of bookings that revenue value falls between a set range. Tried sumifs and sumproduct as think it may need an array, but going round in circles. More info on the attached. https://dl.dropboxusercontent.com/u/9071274/Revenue%20between%20values.xlsx...
  22. M

    Select min value from a range [SOLVED]

    Two gents - if only minif was as simple as sumif ;) Thanks
  23. M

    Select min value from a range [SOLVED]

    Hi all, I'm looking to count values and select min price in the range on a specific date. The count bit is easy, but getting a little stuck trying to find the min value (exc 0). Example here https://dl.dropboxusercontent.com/u/9071274/MinVal.xlsx Thanks Paul
  24. M

    Sumifs to find values between [SOLVED]

    Yeah I use & instead of concatenate for other things but didn't realise I could use it for this purpose. A great tip. thanks
Back
Top