Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Remove last character from var
Message
 
À
22/04/2005 03:13:09
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 8
Divers
Thread ID:
01007370
Message ID:
01007376
Vues:
19
>Hi to all
>
>I have a code which picks up a file name and puts it on the clipboard. The variable picks up an extra back-slash which I don't need. Is there any shortcut to either remove the back-slash at the end of the m.cDir or any other way to go about this.
>
>This is how I remove the slash now :
>ccurrdir="c:\drymat\pdf\"
>cDir=getdir(ccurrdir,"Select a file to attach to email","File selection screen",16384) && 64 for drag and drop folders
>_cliptext=(cDir) &&getfile()
>if right(_cliptext,1)="\"
> nslash=len(_cliptext)
> _cliptext=substr(_cliptext,1,(nSlash-1))
>endif
>
>Thanks for your help. Shafid
ccurrdir="c:\drymat\pdf\"
cDir=getdir(ccurrdir,"Select a file to attach to email","File selection screen",16384)  && 64 for drag and drop folders
_cliptext=JUSTPATH(cDir)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform