Saltar al contenido
View in the app

A better way to browse. Learn more.

Ayuda Excel

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Funcion filesearch en excel 2007

publicado

tengo el siguiente problema quiero migrar una macro que tengo en 2003 a 2007, esta macro me busca un archivo pdf de acuerdo a los parametros que le paso, pero no encuentro la forma de hacerlo funcional en 2007 mi codigo es el siguiente

la parte que esta en negrita es la que no me funciona en la version 2007

Sub Buscar_POs_PDF()

A = 1

B = 1

Path_PDFs = UserForm1.TextBox2.Text & "\"

FechaPDF = UserForm1.TextBox3.Value

Campo_Fecha = Format(FechaPDF, "dd/mm/yyyy")

Windows("Plantilla2.xls").Activate

final = Cells(65536, "A").End(xlUp).Row

Vector_Exclusion(B) = ""

Vector_PDF(A) = ""

Cells(2, 5).Select

For i = 2 To final

UserForm1.Label9.Caption = "PO: " & ActiveCell.Value & " Order Date: " & Cells(i, 17) & " vs. " & UserForm1.TextBox3.Value

Cells(i, 5).Select

'fechaplaced = Format(Cells(i, 17), "dd/mm/yyyy")

If Cells(i, 18) = Campo_Fecha Then

Pedido = ActiveCell.Value

Set fs = Application.FileSearch

With fs

.LookIn = Path_PDFs

.Filename = "PO305_" & Pedido & "*.PDF"

If .Execute() > 0 Then

Vector_PDF(A) = .FoundFiles(.FoundFiles.Count)

A = A + 1

Else

Vector_Exclusion(B) = Pedido

Selection.EntireRow.Delete

B = B + 1

ActiveCell.Offset(-1, 0).Activate

End If

End With

End If

Next

End Sub

Featured Replies

No hay posts para mostrar

Archivado

Este tema está ahora archivado y está cerrado a más respuestas.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.