Search Results - VBForums

Search:

Type: Posts; User: westconn1

Page 1 of 13 1 2 3 4

Search: Search took 0.26 seconds.

  1. MsOf07 Re: [B] Need help declaring Excel correctly to work in my project [/B]

    are you sure there is an activeworkbook at this point?

    i tested in VBA

    Set xl = CreateObject("excel.application")
    Set wb = xl.activeworkbook ' no error here, but wb is still nothing
    MsgBox...
  2. Replies
    1
    Views
    103

    Re: Creating Sunday Crossword Puzzle Grids?

    it will only work, in any version, if it exists already
    i would assume that the idea would have been to define the middle cell of the grid a named range of rngmiddle
  3. Replies
    2
    Views
    76

    Re: Selected printers in VB6

    presumably you could check the printer devicename for
    on someservername
  4. MsOf07 Re: [B] Need help declaring Excel correctly to work in my project [/B]

    i found an example
    http://www.vbforums.com/showthread.php?553179-FAQ-s-OD-How-do-I-open-an-existing-Excel-Workbook
  5. Replies
    3
    Views
    115

    MsOf07 Re: Get selected text in VBA

    i tested my previous suggestion, like


    set myclip = createobject("Clipbrd.Clipboard")
    myclip.clear
    selection.copy
    debug.print myclip.gettext
    use your own method to access the clipboard, you...
  6. Re: Copy and paste Outlook Email bodytext to Word document

    are you writing the code in outlook or word?
    are you trying copy the entire body text?
  7. Replies
    4
    Views
    115

    Re: VB in Excel for newbie

    there are 2 basic methods, open the workbook in excel, visible or not
    or use ADO and return a recordset from the workbook

    i would have though these would have been invalid filenames, containing /s
  8. Re: Excel 2003 - Detect if being run in Office 2010 or later than 2003

    you can check the Application.Version in the workbook open event, if > 12 (or whatever) thisworkbook.close false
    or msgbox "missing Version references"

    but maybe better to remove references to...
  9. Replies
    3
    Views
    115

    MsOf07 Re: Get selected text in VBA

    you could try copying the selection, then retrieve the text from the clipboard
  10. Thread: Dde

    by westconn1
    Replies
    1
    Views
    69

    MsOfVint Re: Dde

    try google
    vba dde tutorial
  11. Re: [VB6] Can SomeOne Please help Me Fix This Code

    shell is a reserved word, you can not use it for a variable
  12. Re: [RESOLVED] run error 1004 - maybe its excel maybe its vb 6

    normally you would use the single click to like this, double click would open the file directly
  13. Re: run error 1004 - maybe its excel maybe its vb 6

    i do not understand why you want to use the textbox as you have a filelist box
    you are setting the workbook filename when you double click the filelist box, so why not just use the selected file?
    ...
  14. Re: run error 1004 - maybe its excel maybe its vb 6

    i do not see a procedure of that or similar name, or any code to open a workbook at all

    there is a module that is not included in the project, with a procedure that shells excel, but does not open...
  15. Replies
    2
    Views
    107

    MsOf10 Re: Externalize VBA Code

    you could shell out to any other program or .vbs script, or use activex .dll files
    i am not sure that is what you are asking though
  16. Re: run error 1004 - maybe its excel maybe its vb 6

    at what point of the code does the error occur?


    is it the path in your datalink file that is incorrect?
  17. Replies
    1
    Views
    95

    MsOf13 Re: Copying an array to another Array

    you would need to either copy the entire array,
    Array2 = Array1

    or dimension the 2nd array to the size of the first one before copying all the elements

    as this looks like a .net error i will...
  18. Replies
    5
    Views
    95

    Re: Conditionally Rename Files

    what happens with your current code? what needs to change?
  19. Replies
    3
    Views
    168

    Re: Looping through a list to find a match

    try a collection instead, much faster
  20. Re: Run-time error 1004: In VB6 when using Range command

    it is much better to work with a fully qualified range, rather than relying on the selection object
    so i would certainly recommend the 2nd example, which is why i asked why selecting

    in the...
  21. Re: Run-time error 1004: In VB6 when using Range command

    you can try

    with excelWSx
    .Range(.Cells(intDownStart, intAcrossStart), .Cells(intDownStart, intAcross)).Select 'Select the range
    end withyour code does not specify that the cells are in the...
  22. Re: Sending emails to a list of recipients containing row values of an excel sheet

    for rw = 2 to 30 ' change to suit
    set msg = ' this depends on the method to be used to send the emails
    msg.body = cells(1, 1) & cells(1, 2) & cells(1, 3) & vbnewline & cells(rw, 1) &...
  23. Re: Can anyone give boolean allowable values for find and replace function

    best to make sure you have the VBA help installed, it is not installed by default when installing office, but is on the media as an option
  24. Re: Is there any other way of trimming the sheet .

    VBA, at least up to 2010, uses Iif or If, same as VB6
  25. Replies
    1
    Views
    181

    Re: Variable not doing as its told!

    try changing the name of the second variable, or use an array, i have struck this before with similar named variables, but not often
  26. Re: Is there any other way of trimming the sheet .

    this is obviously VBA, substitute and rept are worksheetfunctions
    evaluate is not a worksheetfunction in my version of excel, but may be in later versions, else could be using a reference to msscript
  27. Replies
    3
    Views
    188

    Re: terminate exe

    you can try llike

    Dim ret As Long

    Private Sub Command1_Click()
    ret = Shell("notepad.exe", vbNormalFocus)

    End Sub

    Private Sub Command2_Click()
  28. Re: Trouble with what I'm assuming will be insert.after that will be used.

    why not just find ones that match variable?


    Set fnd = thisdocument.range.Find.Execute(myvar, True, True, , , , False)
  29. Re: VB6 Automate sending data to an EMPTY EXCEL ROW / CELL

    Anextrow would be a range, but using late binding, object is fine)
    xlup should be a constant = -4162, you can use a long variable, but must assign the value to the variable
    else you can just use...
  30. Re: Building a TreeView/ListView similar to Windows Explorer for FTP application

    i seem to remember a similar thread started by you in 2011
    http://www.vbforums.com/showthread.php?649217-How-to-do-a-directory-tree-search-on-a-remote-computer

    most of your questions should...
  31. Re: Copy Visible Rows to Variant Array Without Looping

    assuming you have to put some processed values back into the worksheet, i am not sure that using an array is the best way, have you considered a recordset?
  32. Re: VB6 Automate sending data to an EMPTY EXCEL ROW / CELL

    while usedrange should work, it often may give problem, try like

    set Anextrow = TSheet.cells(TSheet.rows.count, 1).end(xlup).offset(1)
    Anextrow.value = T 'Cost Variable declared elswhere...
  33. Re: VB6: PrintToFile with the VB6 Printer-Object

    you want to print to a text file? or a printer driver specific file .prn?
    ps give more detail to the required output, formatted or just data?
  34. Re: Copy Visible Rows to Variant Array Without Looping

    no time to try now, but you should be able to set a range = sht.autofilter
  35. Re: [Word] Macro to find times in document and output any in specific range

    this will change to get the full line for each line with time

    Dim r As Range
    Set r = ActiveDocument.Range
    Selection.Find.ClearFormatting
    With r.Find
    Do While...
  36. Replies
    3
    Views
    170

    Re: Combobox Autowordselect

    can you use multi columns so mr is in a separate column?
  37. Replies
    3
    Views
    170

    Re: Combobox Autowordselect

    what is the problem?, matchentry should work
  38. Re: [Word] Macro to find times in document and output any in specific range

    try like

    mystr = r.text
  39. Replies
    6
    Views
    302

    Re: Need help in excel VBA

    you could use conditional formatting to do this

    if you want help with vba code, i suggest posting a sample workbook, here, with before and after sheets, zip first
  40. Replies
    1
    Views
    141

    Re: Toggle macro to run two macros

    try like

    With ActiveWindow.View
    .ShowRevisionsAndComments = not .ShowRevisionsAndComments
    .RevisionsView = wdRevisionsViewFinal
    End With
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Featured


Click Here to Expand Forum to Full Width