what is the correct url syntax of local csv file?

1284
2
03-15-2018 08:34 AM
WilliamHe
New Contributor

Hi, I need help to create a csvlayer from a local csv file, I tried using "url = file:///c:/local_folder/local_file.csv", but it does not work, the reference said we can use either file or http protocol, what is the correct syntax for the url string to load csv file? Thank you.

Tags (1)
0 Kudos
2 Replies
RobertScheitlin__GISP
MVP Emeritus

William,

   I don't think that using a file:// url is supported but you can see in the drag and drop sample you can use local csv files.

Drag and drop to display data | ArcGIS API for JavaScript 3.23 

0 Kudos
WilliamHe
New Contributor

Robert, Thank you. I have to use the http protocol and it works when the csv file is located in the same website.

0 Kudos