Removing path from file name: I use a SelectFile statement to let the user enter a filename. This works well and SelectFile returns the full path of the selected file. I now need the file name itself without the full path. How can this be done in GuiXT?
You can use the following method. We assume that V[fullpath] contains the full file path retuned by SelectFile, and that the result, i.e. file name without path, should be in V[fname].

Set V[i] "&V[fullpathi]" -stringlength
Set V[k] &V[i]

label check_character

if V[i>0]

Set V[char] "&V[fullpath] (&V[i]-&V[i])"

if V[char=\]
   Set V[i] &V[i] + 1
   Set V[fname] "&V[fullpath] (&V[i]-&V[k])"
else
   Set V[i] &V[i] - 1
  goto check_character
endif