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.

Problema con un formulario excel

publicado

Cada vez que ingreso un registro, a través de un formulario, tengo que cerrar y volver a abrir el formulario para poder introducir otro registro; y, así sucesivamente. Si lo intento registrar a continuación uno de otro, me sale una pantalla que dice:

"Valor de propiedad no válido"

Podría tener algo que ver que los ComboBox del formulario, los tengo con la propiedad MatchEntry en 1-fmMatchEntryComplete, para obligar al usuario a que elija uno de los datos de la lista que se despliega del ComboBox e impedir que pueda escribir cualquier cosa.

Esta la parte del código que utilizo para registrar los datos del UserForm:

PrivateSubcmdRegistra_Click()
DimSalirAsBoolean,EstaHojaAsString
Forn =1To2:IfMe.Controls("textbox"&n)=""ThenSalir=True:GoToVerifica
Next
Forn =1To4:IfMe.Controls("combobox"&n)=""ThenSalir=True:GoToVerifica
Next
IfIsNull(DTPregistro)ThenSalir=True
IfIsNull(DTPentrega)ThenSalir=True
Verifica:
IfSalirThenMsgBox"FALTAN DATOS !!!":ExitSub
Sheets("DATOS").Select
'Con la linea siguiente de código, se cuentan todos los registros que se vayan grabando
'en la Hoja"DATOS"y los copia en la Hoja"INICIO",E2.
Sheets("INICIO").Range("E2")_
.FormulaR1C1="=COUNT(DATOS! RC:RC)"
t =Cells(Rows.Count,1).End(xlUp).Row
Cells(t +1,1)=TextBox1.Text
Cells(t +1,2)=Format(DTPregistro.Value,"yyyy/mm/dd")
Cells(t +1,3)=ComboBox1.Value
Cells(t +1,4)=ComboBox2&" "&TextBox3
Cells(t +1,5)=TextBox2.Text
Cells(t +1,6)=ComboBox3.Value
Cells(t +1,7)=ComboBox4.Value
Cells(t +1,8)=Format(DTPentrega.Value,"yyyy/mm/dd")
Cells(t +1,14)=TextBox4.Text
TextBox1.Text=""
DTPregistro.Value=""
ComboBox1.Value=""
ComboBox2.Value=""
TextBox2.Text=""
ComboBox3.Value=""
ComboBox4.Value=""
DTPentrega.Value=""
TextBox3.Text=""
TextBox4.Text=""
Application.ScreenUpdating=True
UserForm_Initialize
EndSub[/HTML]

Saludos.[/font][/color]

Featured Replies

publicado

Creo que tendría que ver con lo que comentas.........pues al final de tu código estás diciendo que todos los ComboBox son iguales a "".........y dudo que entre el listado de opciones que manejas para ellos esté ese valor.....

Prueba a ver a modificar eso y ver si funciona..........

Un saludo,

Tese

  • 4 weeks later...
publicado
  • Autor

Doy el tema por resuelto.

Gracias.

- - - - - Mensaje combinado - - - - -

Doy el tema por resuelto.

Gracias.

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.