Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Multimedia (https://www.delphipraxis.net/16-multimedia/)
-   -   Delphi Load image from device without letter... (https://www.delphipraxis.net/150478-load-image-device-without-letter.html)

WojTec 18. Apr 2010 10:56


Load image from device without letter...
 
...such as camera or memory card plug-in to printer. So, these devices are represented as normal device, not a disc and internal disc don't have letter. And LoadFromFile is useless. How to get access to these files?

Reinhard Kern 18. Apr 2010 16:13

Re: Load image from device without letter...
 
Zitat:

Zitat von WojTec
...such as camera or memory card plug-in to printer. So, these devices are represented as normal device, not a disc and internal disc don't have letter. And LoadFromFile is useless. How to get access to these files?

Hi, whenever i connect a digital camera or a MP3 player or a memory card to my computer, the contents are displayed (in explorer) as a drive with a new letter - i cannot see a problem.

Reinhard

WojTec 18. Apr 2010 17:26

Re: Load image from device without letter...
 
Liste der Anhänge anzeigen (Anzahl: 1)
MP3, card reader - ok, but not camera, printer or probably phone too. See image.

fatalerror 18. Apr 2010 18:10

Re: Load image from device without letter...
 
normally a drive can have no driveletter in two cases:
1. It is mounted as a folder on another NTFS volume.
2. It is not mounted

in your screenshot you can see the file with an opendialog control, so this code should work:

Delphi-Quellcode:
if OpenDialog1.execute then
begin
    str_path:= ExpandFileName(OpenDialog1.FileName);
    ShowMessage(str_path);
end;
see also ExpandUNCFileName

WojTec 18. Apr 2010 18:34

Re: Load image from device without letter...
 
Don't work, file name from dialog is only file name on device, this function just adds program path to this name and finally file not found.

fatalerror 18. Apr 2010 18:52

Re: Load image from device without letter...
 
Zitat:

Zitat von WojTec
Don't work, file name from dialog is only file name on device, this function just adds program path to this name and finally file not found.

You're right. sorry.

mkinzler 18. Apr 2010 19:05

Re: Load image from device without letter...
 
then you cannot access them that way then you have to user a specific API like TWAIN

omata 18. Apr 2010 19:10

Re: Load image from device without letter...
 
klick


Alle Zeitangaben in WEZ +1. Es ist jetzt 00:07 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz