Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.


Welcome, Guest
Guest Settings
Help

Thread: Deployment path for....


This question is answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 12 - Last Post: Jul 6, 2015 10:04 AM Last Post By: Todd Frankson
Todd Frankson

Posts: 39
Registered: 12/19/14
Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 9:44 AM
System.IOUtils.TPath.GetSharedDocumentsPath
or
System.IOUtils.TPath.GetSharedCameraPath

If I plan to put some shared files in a directory under either of these, what path do I put in deployment manager?
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 10:16 AM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

System.IOUtils.TPath.GetSharedDocumentsPath
or
System.IOUtils.TPath.GetSharedCameraPath

If I plan to put some shared files in a directory under either of
these, what path do I put in deployment manager?

For Android, those paths are documented:

Creating an Android App | Loading and Deploying Files
http://docwiki.embarcadero.com/RADStudio/XE8/en/Creating_an_Android_App#Loading_and_Deploying_Files

When you deploy your application for the Android target platform, if you
plan to provide files along with your application to load those files at
run time, you must first decide whether you want to have them on the internal
device memory or on a external memory (for example, an SD card). After you
decide, use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

...

Use the following code to locate those files at run time:

Delphi:
TPath.Combine(TPath.GetDocumentsPath, 'filename') { Internal }
TPath.Combine(TPath.GetSharedDocumentsPath, 'filename') { External }

C++:
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetDocumentsPath(),
L"filename") // Internal
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetSharedDocumentsPath(),
L"filename") // External

For iOS, it only mentions TPath.GetDocumentsPath():

Creating an iOS App | Loading and Deploying Files
http://docwiki.embarcadero.com/RADStudio/XE8/en/Creating_an_iOS_App#Loading_and_Deploying_Files

When you deploy your application for an iOS device target platform (iOS Device
- 32 bit or iOS Device - 64 bit), if you plan to provide files along with
your application to load those files at run time, use the Deployment Manager
to place those files in the "StartUp\Documents" folder during deployment.

...

Use the following code to locate those files at run time:

Delphi:
TPath.Combine(TPath.GetDocumentsPath, 'filename')

C++:
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetDocumentsPath(),
L"filename")

--
Remy Lebeau (TeamB)
Todd Frankson

Posts: 39
Registered: 12/19/14
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 10:38 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Remy Lebeau (TeamB) wrote:
Todd wrote:

System.IOUtils.TPath.GetSharedDocumentsPath
or
System.IOUtils.TPath.GetSharedCameraPath

If I plan to put some shared files in a directory under either of
these, what path do I put in deployment manager?

For Android, those paths are documented:

Creating an Android App | Loading and Deploying Files
http://docwiki.embarcadero.com/RADStudio/XE8/en/Creating_an_Android_App#Loading_and_Deploying_Files

{quote}
When you deploy your application for the Android target platform, if you
plan to provide files along with your application to load those files at
run time, you must first decide whether you want to have them on the internal
device memory or on a external memory (for example, an SD card). After you
decide, use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

I read that. It is unclear....

If I want a sub directory under either of these folders, say "foo", I should Deploy to assets\foo?

--
Remy Lebeau (TeamB)

Thanks Remy
Markus Humm

Posts: 5,113
Registered: 11/9/03
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 10:56 AM   in response to: Todd Frankson in response to: Todd Frankson
Am 29.06.2015 um 19:38 schrieb Todd Frankson:

[snip]


I read that. It is unclear....

If I want a sub directory under either of these folders, say "foo", I should Deploy to assets\foo?

Sure. Why not?

Greetings

Markus
Todd Frankson

Posts: 39
Registered: 12/19/14
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 11:46 AM   in response to: Markus Humm in response to: Markus Humm
Markus Humm wrote:
Am 29.06.2015 um 19:38 schrieb Todd Frankson:

[snip]


I read that. It is unclear....

If I want a sub directory under either of these folders, say "foo", I should Deploy to assets\foo?

Sure. Why not?

Using assets\foo in deployment manager doesn't put the folder under either of those.....

I need to deploy files to a shared folder. I don't know what to put in the "remote path" in deployment manager to get the folder in either of those directories

Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 12:44 PM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

Using assets\foo in deployment manager doesn't put the folder under
either of those.....

Then where does it put it? You need to ask Embarcadero if that behavior
is a bug or intentional. You might have to deploy to just "assets" and then
move the file to TPath.GetSharedDocumentsPath+'\foo' when your app starts up.

--
Remy Lebeau (TeamB)
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 1, 2015 11:45 AM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

Using assets\foo in deployment manager doesn't put the folder under
either of those.....

Then where does it put it? You need to ask Embarcadero if that behavior
is a bug or intentional. You might have to deploy to just "assets" and then
move the file to TPath.GetSharedDocumentsPath+'\foo' when your app starts up.

--
Remy Lebeau (TeamB)
Todd Frankson

Posts: 39
Registered: 12/19/14
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 6, 2015 10:04 AM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Remy Lebeau (TeamB) wrote:
Todd wrote:

Using assets\foo in deployment manager doesn't put the folder under
either of those.....

Then where does it put it? You need to ask Embarcadero if that behavior
is a bug or intentional. You might have to deploy to just "assets" and then
move the file to TPath.GetSharedDocumentsPath+'\foo' when your app starts up.

Finally can get to reply on this darn server!

It deploys them to a private folder under emulated/0/private.../files

I am attempting to copy but it seems that android doesn't like to cooperate.
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 12:09 PM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

I read that. It is unclear....

Read it again more carefully:

... use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

If I want a sub directory under either of these folders, say "foo", I
should Deploy to assets\foo?

Yes, for external storage, and "assets\internal\foo" for internal storage.

--
Remy Lebeau (TeamB)
Todd Frankson

Posts: 39
Registered: 12/19/14
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 12:42 PM   in response to: Remy Lebeau (Te... in response to: Remy Lebeau (Te...
Remy Lebeau (TeamB) wrote:
Todd wrote:

I read that. It is unclear....

Read it again more carefully:

... use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

If I want a sub directory under either of these folders, say "foo", I
should Deploy to assets\foo?

Yes, for external storage, and "assets\internal\foo" for internal storage.

And like I said, Doing that does not Deploy the files to the tpath.GetCameraPath\foo or the TPath.GetsharedDocumentspath\foo folders
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jun 29, 2015 2:41 PM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

And like I said, Doing that does not Deploy the files to the
tpath.GetCameraPath\foo or the TPath.GetsharedDocumentspath\foo
folders

What does GetCameraPath have to do with anything? You have to use GetDocumentsPath()
instead.

In any case, if the IDE does not allow deploying to a subfolder, then you
will have to deploy to the base documents folder and move the file once your
app is running. File a feature request in QualityPortal for deploying files
to a subfolder.

--
Remy Lebeau (TeamB)
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 1, 2015 11:45 AM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

I read that. It is unclear....

Read it again more carefully:

... use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

If I want a sub directory under either of these folders, say "foo", I
should Deploy to assets\foo?

Yes, for external storage, and "assets\internal\foo" for internal storage.

--
Remy Lebeau (TeamB)
Remy Lebeau (Te...


Posts: 9,447
Registered: 12/23/01
Re: Deployment path for....  
Click to report abuse...   Click to reply to this thread Reply
  Posted: Jul 1, 2015 11:45 AM   in response to: Todd Frankson in response to: Todd Frankson
Todd wrote:

System.IOUtils.TPath.GetSharedDocumentsPath
or
System.IOUtils.TPath.GetSharedCameraPath

If I plan to put some shared files in a directory under either of
these, what path do I put in deployment manager?

For Android, those paths are documented:

Creating an Android App | Loading and Deploying Files
http://docwiki.embarcadero.com/RADStudio/XE8/en/Creating_an_Android_App#Loading_and_Deploying_Files

When you deploy your application for the Android target platform, if you
plan to provide files along with your application to load those files at
run time, you must first decide whether you want to have them on the internal
device memory or on a external memory (for example, an SD card). After you
decide, use the Deployment Manager to place those files in the "assets\internal"
(internal) or "assets" (external) folder during deployment.

...

Use the following code to locate those files at run time:

Delphi:
TPath.Combine(TPath.GetDocumentsPath, 'filename') { Internal }
TPath.Combine(TPath.GetSharedDocumentsPath, 'filename') { External }

C++:
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetDocumentsPath(),
L"filename") // Internal
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetSharedDocumentsPath(),
L"filename") // External

For iOS, it only mentions TPath.GetDocumentsPath():

Creating an iOS App | Loading and Deploying Files
http://docwiki.embarcadero.com/RADStudio/XE8/en/Creating_an_iOS_App#Loading_and_Deploying_Files

When you deploy your application for an iOS device target platform (iOS Device
- 32 bit or iOS Device - 64 bit), if you plan to provide files along with
your application to load those files at run time, use the Deployment Manager
to place those files in the "StartUp\Documents" folder during deployment.

...

Use the following code to locate those files at run time:

Delphi:
TPath.Combine(TPath.GetDocumentsPath, 'filename')

C++:
System::Ioutils::TPath::Combine(System::Ioutils::TPath::GetDocumentsPath(),
L"filename")

--
Remy Lebeau (TeamB)
Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02