public void ImportFromFile(string path, string pathtoafc = "")
{
if (FileName == "")
return;
if (pathtoafc != "")
{
if (File.Exists(pathtoafc + FileName + ".afc"))
ImportWav(pathtoafc + FileName + ".afc", path, DataOffset);
else
{
OpenFileDialog d = new OpenFileDialog();
d.Filter = FileName + ".afc|" + FileName + ".afc";
if (d.ShowDialog() == DialogResult.OK)
ImportWav(d.FileName, path, DataOffset);
}
}
else
{
OpenFileDialog d = new OpenFileDialog();
d.Filter = FileName + ".afc|" + FileName + ".afc";
if (d.ShowDialog() == DialogResult.OK)
ImportWav(d.FileName, path, DataOffset);
}
}