Search:

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

Page 1 of 6 1 2 3 4

Search: Search took 0.04 seconds.

  1. Replies
    2
    Views
    112

    Re: Modeless form with "Cancel" button

    try to put DoEvents in between separate procedures to see if this helps.
    The other thing to check is if you can interact with form2 even when no code is running ?
  2. Replies
    2
    Views
    126

    Re: Disabling certain codes

    try this function in an IF statement:

    Function SheetIsBlank(ByVal wsh As Worksheet) As Boolean On Error Resume Next
    Dim rng As Range
    Set rng = wsh.UsedRange
    If rng Is Nothing...
  3. Re: Overflow error, but I can't get it to repeat it

    did you try using double instead of single.
    Can't really get my head around the issue completely, just this is the first thing that comes to mind.
  4. Replies
    2
    Views
    108

    Re: Convert to Long Integer in Loop

    It will be more interesting to see the code that does the import, if it is done by code that is.
    Do you run the import code from access or from excel.
    If you do it manually you can easily change...
  5. Re: Using Listbox value to display png in image box

    ... and includes the full path to the image?
    Can you confirm this is the actual VALUE of the listbox?
    Can you also include in your code the next line and report on the result displayed in the...
  6. Replies
    2
    Views
    139

    Re: Macro to set a path

    try like this:

    Set wbCopyTo = Application.Workbooks.Open ("C:\Result\ABC.xlsx")
    Set wsCopyTo = wbCopyTo.Sheet2
  7. Re: Using Listbox value to display png in image box

    make sure that ListBox1.Value is actually a valid image filename (it may not always be what you see) and including the path to it.
  8. Re: how to count the total llines in all files in all subfolders

    Why would you bother with code?
    Your post shows that you want to use it as formula.
    So if the filenames list is in column A starting from A1, then simply put this formula in column B starting from...
  9. Re: how to count the total llines in all files in all subfolders

    ....
    Sub ScanFilesInSubfolders()
    On Error GoTo errHandler

    'Select folder to be scanned
    Dim root As String: root ="your folder path here"
    If UCase(root) = "FALSE" Then Exit Sub...
  10. Re: how to count the total llines in all files in all subfolders

    When you run it you will get a dialog box to select the folder.
  11. Re: Help to check value, if one of value 0 then that row mark red

    If the macro doesn't clear formatting and conditional formatting the above suggestions should work (really depending on what the macro does).

    Anyway, you can use something like this code:


    Sub...
  12. Replies
    5
    Views
    214

    Re: Analyze workbook calculation time

    The best measurement is the feeling you get when you use the workbook and you know a bit more about it - size, complexity, amount of data, etc.
    Once you feel there is a problem with productivity you...
  13. Replies
    5
    Views
    214

    Re: Analyze workbook calculation time

    Well there are 3 types of cells - Blanks(or Empty), Cells with values (constant text, number, date, etc.) , cells with formulas (which actually need to be recalculated)
    So only checking for empty...
  14. Re: Help to check value, if one of value 0 then that row mark red

    Good point, Rick - my mistake. Thanks for pointing it out.

    Still if adding is used - it has to be combined with ABS() otherwise the result can still be zero even if the numbers are not.
  15. Re: how to count the total llines in all files in all subfolders

    Below is a code which will create a list of all files in a selected folder from the active cell down (start the macro called ScanFilesInSubfolders)
    Then you can use the filenames to get the line...
  16. Replies
    5
    Views
    214

    Re: Analyze workbook calculation time

    For me - the limitation is that the output does not actually allow any analysis to be made.
    To analyse data you have to put it all together on one sheet structured in the same way. Only then you can...
  17. Re: Help to check value, if one of value 0 then that row mark red

    I wouldn't use a macro, but Conditional formatting with a formula like this:

    =OR(S1<>0,T1<>0,U1<>0,V1<>0,W1<>0,X1<>0)
    or this:

    =S1*T1*U1*V1*W1*X1<>0

    to simplify you can use the formula...
  18. Re: Excel Formula for File Name but Do Not Change if Workbook Not Active

    You can use any cell regardless of its contents.
  19. Re: how to call a workbook without knowing the name vba

    something like this:


    ....
    Dim objFolder As Object
    Set objFolder = CreateObject("Scripting.FileSystemObject").getfolder(strDirectory) 'strDirectory - this argument you get from your...
  20. Re: Loading dots splash screen on Workbook_Open

    Is it a heavy workbook? Does loading take long time?
    If there are a lot of background operations going on refreshing the form will not be top priority while the workbook is loading.
    Maybe including...
  21. Re: Loading dots splash screen on Workbook_Open

    Can you include in your post the HideTitleBar, FindWindow functions and associated APIs, constants etc.
    e.g. SetWindowLong, SetLayeredWindowAttributes, ....

    Is your Form called "Loading"?
  22. Replies
    1
    Views
    117

    Re: Struggling To Amend Code

    something like this:


    Option Explicit


    Sub MergeSpecificWorkbooks()
    Dim MyPath As String
    Dim SourceRcount As Long, FNum As Long
    Dim mybook As Workbook, BaseWks As Worksheet
  23. Re: Excel Formula for File Name but Do Not Change if Workbook Not Active

    Use a cell reference in the file as optional function argument:

    CELL("filename",$A$1)
  24. Re: All graphic objects have lost their assigned macro

    What is the file format? Is it possible that you have saved the file as XLSX (no-macro)?

    Is the code for the macros still in the workbook? Or just the assignments have gone?
  25. Replies
    6
    Views
    247

    Re: Movable Macro button

    You will have to include any code needed to move the button in the code for Worksheet Selection Change Event.
Results 1 to 25 of 150
Page 1 of 6 1 2 3 4