https://foro.gambas-es.org/viewtopic.php?f=5&t=6261&p=37456#p37456
-----------------------------------
vuott
Lunes, 03 Abril 2017, 19:54

Re: Directorio Padre De Otro Directorio
-----------------------------------
Sólo por curiosidad, es posible utilizar la función externa "[i]dirname( )[/i]" de la libreria [i]libc.so.6[/i].

[i]Exemplum simplex[/i]:
[code linenumbers=false syntax=gambas]Library "libc:6"

' char *dirname (char *__path)
' Return directory part of PATH or "." if none is available.
Private Extern dirname(__path As String) As String


Public Sub Main()
 
 Dim s As String
 
  s = dirname("/dev/snd")
  
  Print s
  
End[/code]


