Search:

Type: Posts; User: jkpieterse; Keyword(s):

Page 1 of 6 1 2 3 4

Search: Search took 0.07 seconds.

  1. Replies
    4
    Views
    119

    Re: VBA access query using AND & Or

    I expect so, but I think you have two " characters too many and your codeline should look like this:

    strQuery = "SELECT Name, Wage, Pre_App_Adds, Food, Home_Start, Other, Mileage_Pay, Holiday_Pay,...
  2. Re: Excel selects cell O75 on SAVE when top row is frozen

    Sounds as if the system somehow presses the control+End key. Any add-ins loaded?
  3. Re: Excel selects cell O75 on SAVE when top row is frozen

    To be clear: does it happen in safe mode AND when the top row is frozen?
  4. Re: Excel selects cell O75 on SAVE when top row is frozen

    Does it also happen when you open Excel in safe mode? (press and hold the control key when Excel starts)
  5. Re: Save button giving error when file extensions are active on PC

    If I recall correctly you can add the extension to your code and it will keep working whether or not file extensions are visible.

    So change

    Windows("Import Data").Activate to
    Windows("Import...
  6. Re: How to track changes of a shared workbook in a separate workbook

    That wouldn't help, as the code would still have to work with the workbook in question and hence be running in the same instance of Excel.
  7. Re: Connectionstring not being set properly by code - query data source not changing

    Have you actually tried changing the connection manually through the Excel user interface? I see you're using a dropbox folder, maybe Excel doesn't like that?
  8. Replies
    13
    Views
    515

    Re: Get Worksheet Name from CodeName

    When you copy a worksheet it always becomes the activesheet, so if you catch the name (or set an object reference) of the activesheet just after the copy, you're good to go.
  9. Re: Connectionstring not being set properly by code - query data source not changing

    Given that you are trying to update Querytables and not tables you need a different object than ThisWOrkbook.QUeries:

    Sub UpdateQueryTables()
    Dim Qt As QueryTable
    Dim Sh As Worksheet
    ...
  10. Replies
    13
    Views
    515

    Re: Get Worksheet Name from CodeName

    You already have the name! After your code has hit this line in your macro:

    sInterimName = ActiveSheet.Name
  11. Re: Connectionstring not being set properly by code - query data source not changing

    You're currently assigning a text value to the variable called Connectionstring. But you do not use that string to update any property of q.
  12. Replies
    13
    Views
    515

    Re: Get Worksheet Name from CodeName

    I'm not sure why you want to use the codename?
  13. Re: Comparing 2 worksheets and displaying differences

    Perhaps this little tool might help:
    https://jkp-ads.com/download.asp#Compare2Tables
  14. Re: Excel 2010 Macros not running in Excel 2016

    NB: The MISSING ref is due to the fact that the calendar control is no longer part of Office. There are good alternatives to that, such as this one:...
  15. Re: Hello Excel gods Please how can I convert a PDF file to Excel is there a good way to do ?

    If you have Word 2016 or 365, open the file in Word. Then you can copy and paste into Excel
  16. Re: Excel 2010 Macros not running in Excel 2016

    It is the MISSING reference which causes most of your compile errors. Uncheck that and you should be good to go mostly.
  17. Re: How to stop a Macro-Enabled Template from saving and adding a "1" to the file name

    Very strange. I've tested the code and when you open a file from the template it does show the 1, which gets removed if you try to save the copy.
  18. Re: How to stop a Macro-Enabled Template from saving and adding a "1" to the file name

    Have you tried to save the file once opened from the template? I guess not.
  19. Re: How to stop a Macro-Enabled Template from saving and adding a "1" to the file name

    Something like this:

    Option Explicit

    Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
    Dim sName As String
    Dim sSaveName As String
    Dim bSave As...
  20. Re: How to stop a Macro-Enabled Template from saving and adding a "1" to the file name

    It is by design that Excel adds a 1 after the original name of a template when opened. There is nothing you can change about that, except writing VBA code in the Workbook_BeforeSave routine to...
  21. Replies
    3
    Views
    87

    Re: Error in IFERROR formula

    DOuble quotes need to be escaped:

    Worksheets("Filtered Data").Range("I2:I" & LastRow).Formula = "=IFERROR(IF(SEARCH(I$1,$B2)>0,I$1,),"" - "")"
  22. Replies
    15
    Views
    335

    Re: Autofill AAAA-AAAB etc

    You do know that means about half a million rows? This can be done using PowerQuery. Which Excel version are you using?
  23. Replies
    5
    Views
    214

    Re: Need help with VBA

    You've added too many " and one ) too little :-) this is correct:

    Target.Formula = "=IF(C" & ActiveCell.Row & "="""",F" & ActiveCell.Row - 1 & "+ CK" & ActiveCell.Row - 1 & ",If(C" &...
  24. Re: Help & Advice On A VLookup/Match Maybe?

    Can you post a link to a sample Excel file please? Without any sensitive data of course...
  25. Replies
    5
    Views
    214

    Re: Need help with VBA

    You should double each " that is to be visible in the formula. So if the formula contains "", your VBA should show """" at that location. This does not include the starting and ending quotes of the...
Results 1 to 25 of 150
Page 1 of 6 1 2 3 4