Hello, I’ve got a problem with this following script, my aim is to stock data in a txt file, when I try to store the data from an eye tracker (lines in comments) it works instead that the others lines do not appears and that the name of the txt file is the one that I’ve used before changing my script so I find it very weird because the name of my txt file is the old one and not the new one. But when I try the script without trying to store data from an eye tracker, nothing is record and the txt file is not creates.
using UnityEngine;
using System.Text;
using System;
using System.Collections.Generic;
using UnityEngine.UI;
using System.IO;
using System.Linq;
//using Newtonsoft.Json;
//using TETCSharpClient;
//using TETCSharpClient.Data;
public class Enregistrements : MonoBehaviour{
// public string folder = "Enregistrements";
//public static void essai (GazeData gazeData)
public static void trial()
{
using (StreamWriter sw = new StreamWriter ("test.txt"))
{
sw.WriteLine("Coordinates in X" + ";" + "Coordinates in y");
//sw.WriteLine ( gazeData.SmoothedCoordinates.X + ":" + gazeData.SmoothedCoordinates.Y + ":" + Time.time);
sw.WriteLine(Time.time);
}
}
}
Did someone have an idea of how the problem can be solved ?
Thanks vey much