0

I'm building MVC application and trying to refresh DropBox token using Chilkat library. https://www.example-code.com/csharp/dropbox_refresh_token.asp

When I'm trying this

Chilkat.JsonObject json = new Chilkat.JsonObject();
success = json.LoadFile("qa_data/tokens/dropbox.json");

I got an error:

ChilkatLog:


 LoadFile:
ChilkatVersion: 9.5.0.93
loadFileX:
  Failed to open file (3)
  filePath: \\?\C:\Windows\SysWOW64\inetsrv\qa_data\tokens\dropbox.json
  osErrorInfo: The system cannot find the path specified.
  windowsError: 3
  localWindowsFilePath: qa_data\tokens\dropbox.json
  Failed to open for read.
--loadFileX
Ann
  • 35
  • 10

1 Answers1

0

The argument passed to json.LoadFile is a file path, which can be an absolute path, or a relative path. A relative path, such as "qa_data/tokens/dropbox.json" is relative to the current working directory of the process. If you don't understand relative paths or the concept of "current working directory", see https://en.wikipedia.org/wiki/Working_directory

You could instead pass an absolute file path, such as @"C:\someDir\someOtherDir\dropbox.json"

Chilkat Software
  • 1,405
  • 1
  • 9
  • 8
  • Thank you. I cheked path C:\Windows\SysWOW64\inetsrv and it's empty. There no file there. Can you please tell me where I can download dropbox.json file to put by right path? – Ann Feb 13 '23 at 18:25