?
Solved

read filename from TPicture

Posted on 2003-11-07
3
Medium Priority
?
170 Views
Last Modified: 2010-04-05
hi...

i can't find the way to extract the filename of the associated file of a TPicture...

i assign the file with something like:

img := TPicture.Create;
img.LoadFromFile('the_file');

but i need to extract that filename... how do i do that?

thank u for your answers.
0
Comment
Question by:corsita
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 12

Accepted Solution

by:
andrewjb earned 200 total points
ID: 9703469
A TImage doesn't remember where it loaded from. You'll have to store it separately somewhere, or derive a new component from TImage

0
 

Author Comment

by:corsita
ID: 9709310
really? ... that's weird...

ok thanks for that!
0
 
LVL 5

Expert Comment

by:Hypoviax
ID: 9711858
How about when you load the file you save the file path to a variable named something like:

            picfilename

...as a string of course

Then when you want the filename simply refer to this variable.

Regards,

Hypoviax
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Suggested Courses
Course of the Month8 days, 18 hours left to enroll

765 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