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.

Crear horas en formato texto a formato horas y minutos

publicado

Buenos días amigos de la comunidad,

Tengo un fichero que extraigo todos los meses de nuestra plataforma de fichajes y es formato csv.

Yo lo convierto a xlsb y genero una tabla para poder explotar los datos.

 

Mi problema como podeis observar es que el campo duración me lo saca en texto 9h 32m, me gustaría poder convertirlos a formato hora para que me aparezca 09:30.  

Subo el fichero

 

Alguien me puede ayudar?

 

Gracias anticipadas. 

Histórico01-01-202131-01-2021 2.csv

Featured Replies

publicado

Mira a ver si te vale esta macro. No me deja adjuntar el archivo.

Sub SustituirStrings()
    Dim rHoras As Range, rTabla As Range, rDatos As Range
    Dim sh As Worksheet
    
    Set sh = ActiveSheet
    
    Set rTabla = sh.UsedRange
    
    Set rDatos = rTabla.Offset(1).Resize(rTabla.Rows.Count - 1)
    
    With rDatos
        Set rHoras = Union(.Columns(14), .Columns(15), .Columns(16), .Columns(18), .Columns(19))
        
        With rHoras
            .Replace "h ", ":", xlPart
            .Replace "m", "", xlPart
            
            .NumberFormat = "hh:mm"
        End With
    End With
End Sub

 

Editado el por overdrive

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.