Forum Xamarin.iOS

How to locate directory resource in Xamarin ios

I am currently working with Xamarin.iOS platform and trying to fetch data from directory inside in my project resource and project directory. But could not able to get data while fetching information. Even I can see whole directory is not copied in application bundle itself.

Below is my code.

string localHtmlUrl = Path.Combine(NSBundle.MainBundle.BundlePath, string.Format("NewFolder/webref/index.html"));


  • FionaCFionaC IEMember ✭✭

    What is the build action on your file? It should be set to BundleResource

  • DmzDkDmzDk USMember

    //get the route from ios where you can host files or create
    var documentsPath = Environment.GetFolderPath (Environment.SpecialFolder.Personal);
    var filePath = Path.Combine (documentsPath, fileName);

  • AshMCAAshMCA Member

    Am facing the same issue did you got the solution?please replay back Vigneshc.2827

Sign In or Register to comment.