Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TClientDataset in OS X Firemonkey App

I have a Windows Firemonkey app that uses TClientDatasets to load XML data files that I'm trying to get to work on OS X. The data files are stored on a Windows file share so multiple users can access the same data (I'm not concerned about concurrency issues here).

I can't seem to get the mac version load the files from the server - it seems to automatically preppend the local path to whatever I set in the TClientDataset.Filename property.

If I copy the datafiles into the app package before starting the app, it works perfectly, so I figured I'd try to copy the files in code, but I can't get that to work either - it can't find the files on the server.

TFile.Exists('smb://<servername>/<path>/Data.xml');

Returns FALSE despite the fact I can see it in Finder.

Ideally, I'd prefer to load the files from the share rather than copy them at startup and copy back on exit.

like image 596
Joel Barker Avatar asked Apr 16 '12 01:04

Joel Barker


1 Answers

I had a similar problem and worked it out by creating one tcp server on the windows side and one tcp client on the client side.. and sending the xml file through streams.. works like a charm ...

like image 91
Tony Hanna Avatar answered Sep 28 '22 07:09

Tony Hanna