Solved

Removing path from filename

Posted on 1998-03-26
1
120 Views
Last Modified: 2010-04-06
Hi,
   In my app I run an external program which takes the name of the current document as a parameter. Is there an easy way to remove all the path information ie. c:\prodelph\doc.tex should be given as doc.tex?
Cheers.
0
Comment
Question by:PiersBull
1 Comment
 
LVL 2

Accepted Solution

by:
rene100 earned 10 total points
ID: 1360887
Hi PiersBull

use the ExtractFileName function (unit SysUtils), i.e.

ExtractFileName('c:\windows\myfile.ext') returns 'myfile.ext'

hope this help

rene100
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now