Search results

  1. HaHoBe

    Filter 2 specific columns?

    Hi, chergh, you´re right about the adjacent columns regarding the manual use of the autofilter. But using VBA I´d take this road: Sub ApplyAutofiterToColumns_E_And_G() Dim rngCell As Range Application.ScreenUpdating = False 'assuming that the Filter is to be set in the first row of the...
  2. HaHoBe

    printing pdf files using vba in excel

    Hi, eddie1980, depends on how you ant to approach: either just change the printer for the output (try recording a macro by going through this process) or maybe use ShellExecute and the Acrobat Reader (if the file is already present on the PC). Ciao, Holger
  3. HaHoBe

    Filter 2 specific columns?

    Hi, laxster, mark only cells E1 and F1 and call the autofilter or use Range("E1:F1").AutoFilter in VBA after checking about FiulterMode. Ciao, Holger
  4. HaHoBe

    Unable to Locate Formula Error

    Hi, LadyDi, which version of Excel? Up to Excel2003 please check Edit/Reference for help. To find the erreanous cell F5/Contents/Formulas with only Errors may help (needs to be done on any worksheet individually or by VBA, please only have one cell selected for working on the whole worksheet...
  5. HaHoBe

    Macros in 2007

    Hi, Deborah, in none of the Versions I own (Excel97 to Excel2010 - all for Windows) the Range-Object has a Start-Value - if you created a class giving the Range that attribute you should tell us about that. Range("A3").Borders = "[$-409]mmmm d, yyyy;@" This line of code is wrong as border...
  6. HaHoBe

    Convert to Text

    Hi, BazLondon, so only that person can give more information? ;) It depends on where you want to use the code - if it´s only one workbook the code goes into a module. If you need it in differnet workbooks (and only you should utilze it) the personal macroworkbook (or an addin) should be...
  7. HaHoBe

    Convert to Text

    Hi, BazLondon, if you really want to use VBA the following macros should do the trick: Sub ConvertToStrings() Dim lngLastRow As Long Dim lngCounter As Long Const cstrSourceCol As String = "A" Const cstrResultCol As String = "D" Application.ScreenUpdating = False lngLastRow = Cells(Rows.Count...
  8. HaHoBe

    Auto Update

    Hi, Justin, maybe Application.OnTime can help: 'Code for ThisWorkbook Private Sub Workbook_BeforeClose(Cancel As Boolean) On Error Resume Next Call EndProcessing End Sub Private Sub Workbook_Open() StartProcessing End Sub 'module Public Const ciIntervall As Integer = 10 Public...
  9. HaHoBe

    why cant I open this file?

    Hi, smiler44, why don´t you use the FileFormat for SaveAs as described in Use VBA SaveAs in Excel 2007? Maybe the standard saving isn´t *.xlsx but *.xls. Now gives both Date and Time but for getting out the year Date alone should do well. And for getting the Name of a workbook you could make...
  10. HaHoBe

    Consolidating Tabs In Excel

    Hi, brian4167, just follow the wizard but keep in mind that this procedure will only show the reults for any group (similar to a pivot table). If you really need all data in one worksheet maybe the following macro can givbe you a start: Sub CopyFromWorksheets() ' smozgur...
  11. HaHoBe

    Consolidating Tabs In Excel

    Hi, brian4167, what about Data/Consolidation or the use of VBA to create a single worksheet with all information? Ciao, Holger
  12. HaHoBe

    Truncate Characters from a Cell

    Hi, noboffinme, wrong position of parenthesis for the length of the Cells-Value? Sub right_char_trim() Dim i As Long For i = ActiveSheet.Cells(Rows.Count, "A").End(xlUp).Row To 2 Step -1 Cells(i, 1) = Mid(Cells(i, 1), 1, Len(Cells(i, 1)) - 4) Next i End Sub To indicate whether the start...
  13. HaHoBe

    VBA Code To Repeatedly Clear Cell Contents

    Hi, Growlos, Dim rngCell As Range If [F2] <> "Suspended" And [E2] <> "In Play" Then For Each rngCell In Range("T5:T24") If UCase(rngCell) <> "PENDING" Then rngCell.Value = vbNullString End If Next rngCell End If Ciao, Holger
  14. HaHoBe

    Highlight whole row as cursor moves

    Hi, bulrush, please mind that code will clear all other colors, goes behind the worksheet: Public mlngOldRow As Long Private Sub Worksheet_Activate() mlngOldRow = ActiveCell.Row End Sub Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range) If mlngOldRow > 0 Then...
  15. HaHoBe

    Selecting filtered dates from a VBA FORM to run in an AutoFilter macro

    Hi, Terry, sorry for the late answer. I changed the Userform to show the uniques from a slightly modified worksheet CRSUM. To apply the autofilter in sheet CRSUM please use the button. Closing the Form at present is only possible via the X: Option Explicit 'Option Base 1 Private Sub...
  16. HaHoBe

    Excel newbie

    Hi, , what are you after (sorry but non-english speaking foreigner doesn´t get the point ;))? What MS generally does is putting only part of the information into one worksheet at a time instead of users who want to do it all in one worksheet. Ciao, Holger
  17. HaHoBe

    Add or Sub Time

    Hi, Bob, shouldn´t it be Finsih Time - Start Time? Please mind that Excel in normal mode cannot display negative times (only if you change Tools/Options/Calculate to 1904-Dates which will affect all dates esp. in linked workbooks). Format the cell(s) for the sum as [h]:mm. Ciao, Holger
  18. HaHoBe

    copy first cell that doesn't have a zero in it

    Hi, elfranzen, what is returned inside that procedure is the counter (as AB1008 happens to be located in Column 28 where the search range starts). Dim lngColCounter As Long With Sheets("summary") For lngColCounter = .Range("AB1008").End(xlToLeft).Column To 1 Step -1 ' If...
  19. HaHoBe

    Selecting filtered dates from a VBA FORM to run in an AutoFilter macro

    Hi, Terry, can you please attach a sample of your workbook to have a look at it? Ciao, Holger
  20. HaHoBe

    Run functiion if cells values change

    Hi, IainG, have a look at the Worksheet_Calculate event. Please mind that there are some restrictions to the use of a function when used in a worksheet. Ciao, Holger
Back
Top Bottom