question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

how can i change the file destination when i capture() it? the uri puts it in a folder where it is hidden and cannot be seen in my phone file manager.

For example i wanted to save it in Download folder…

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5

github_iconTop GitHub Comments

2reactions
alz10commented, Jul 20, 2018

solved: Using rn-fetch-blob

saveQrCode() {
    const PATH_TO_WRITE = `${RNFetchBlob.fs.dirs.DownloadDir}/test.png`;

    this.refs.viewShot.capture().then(data => {
      RNFetchBlob.fs.writeFile(PATH_TO_WRITE, data, "base64").then(() => {
        ToastAndroid.show("Saved to gallery !!", ToastAndroid.SHORT);
      });
    });
  }
0reactions
Piyush132000commented, Dec 9, 2020

hlo friends, i am here with solution of this problem , For solving this problem you have to go on your App permission on your real mobile and allow for camera storage then you can easily save your ViewShot on Your Mobile.

go to App Permisssion in your App.info allow Camera accesss storage

Read more comments on GitHub >

github_iconTop Results From Across the Web

c# - Convert file path to a file URI?
The workaround is simple. Just use the Uri().ToString() method and percent-encode white-spaces, ...
Read more >
Renaming a file and Creating a URI
I would like to change the files names to: FirstName LastName. I would also like to create a URI for each. So, remove...
Read more >
Convert local file path to URL & URI in java (example)
Given a File in java. We would like to convert local file path to URL & URI path (example). We will use toURL()...
Read more >
How can I convert a UNC Windows file path to a File URI ...
Converting the above UNC path into a file URI is extremely simple using PowerShell (all versions), and requires only the format and replace ......
Read more >
file-uri-to-path
Convert a file: URI to a file path. Latest version: 2.0.0, ... Start using file-uri-to-path in your project by running `npm i file-uri-to-path`....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found