I need to share Multiple files using NativeShare(). How do i add path of second file?
I need to attach two text files on a single button press in unity. I can send single file.
Here's the code:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System.IO;
using System;
public class ShareButton : MonoBehaviour
{
// Start is called before the first frame update
public void ClickShare()
{
StartCoroutine(Share());
}
private IEnumerator Share()
{
yield return new WaitForEndOfFrame();
new NativeShare().AddFile(filePath).SetSubject("Vologram Results").SetText("Here are the results").Share();
//new NativeShare().AddFile(ffilePath).SetSubject("Vologram Results").SetText("Here are the results").Share();
}
I need to share Multiple files using NativeShare(). How do i add path of second file? I need to attach two text files on a single button press in unity. I can send single file. Here's the code:
using System.Collections; using System.Collections.Generic; using UnityEngine; using System.IO; using System;
public class ShareButton : MonoBehaviour { // Start is called before the first frame update public void ClickShare() { StartCoroutine(Share()); }
}