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.

Problemas al cargar Userform

publicado

Hola buenas tardes,

Tengo un problema que no me deja iniciar el UserForm y no se a que se debe....

Me salta el siguiente error

error.thumb.JPG.27e55e6d26bda911ac47a6f37c8f5a69.JPG

La verdad que no se porque me pasa esto ya que estaba trabajando con el formulario y de repente no me deja iniciarlo.

Dejo el archivo adjunto

Un saludo,

VBA3.xlsm

Featured Replies

publicado
  • Autor

Hola @JSDJSD,

Por lo que veo, el problema lo tengo al querer ejecutar esta macro

Private Sub Cargar(ComboBox As Control, Hoja As Worksheet, Columna As String)
With Hoja
   .Columns(Columna).Copy .Columns(Columns.Count)
   .Cells(1, Columns.Count).Delete
   .Columns(Columns.Count).Sort Key1:=.Columns(Columns.Count)
   .Columns(Columns.Count).RemoveDuplicates Columns:=1
   ComboBox.ShowDropButtonWhen = fmShowDropButtonWhenNever
   ComboBox.List = .Range(.Cells(1, Columns.Count), .Cells(Rows.Count, Columns.Count).End(xlUp)).Value
   .Columns(Columns.Count).Clear
End With
End Sub

Esta macro lo que me hace es el autor relleno de los comboBox al escribir, y la verdad que necesito tenerlo activo...

Que solución puedo aplicar?

Un saludo,

publicado
  • Autor

Ya lo tengo solucionado :)

Adjunto código por si le sirve a alguien

Private Sub UserForm_Initialize()

Dim fila, final, i As Long
Dim lista As String

Sheets("BD").Activate
    fila = Hoja1.Range("A" & Rows.Count).End(xlUp).Row + 1
    final = fila - 1
    For i = 2 To final
        lista = Hoja1.Cells(i, 4)
        txt_proveedor.AddItem (lista)
        lista = Hoja1.Cells(i, 3)
        txt_transportista.AddItem (lista)
        lista = Hoja1.Cells(i, 6)
        txt_contacto.AddItem (lista)
        lista = Hoja1.Cells(i, 7)
        txt_departamento.AddItem (lista)
        lista = Hoja1.Cells(i, 8)
        txt_observaciones.AddItem (lista)
        lista = Hoja1.Cells(i, 10)
        txt_personaentrega.AddItem (lista)
        lista = Hoja1.Cells(i, 7)
        txt_busdepartamento.AddItem (lista)
        lista = Hoja1.Cells(i, 6)
        txt_bus_contacto.AddItem (lista)
    Next i

Gracias un saludo!

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.