Exemplo n.º 1
0
 private void ShowPresetPicker()
 {
     CSVHelper.ReadInputFromString(
         defaultCSV.text,
         microgrid,
         MGMisc.GetInputVars());
     presetPickerWindow.Show(microgrid.Input);
 }
Exemplo n.º 2
0
        private void LoadFromString(string content, MicrogridVar[] mVars = null)
        {
            try
            {
                CSVHelper.ReadInputFromString(content, microgrid, mVars);
            }
            catch (Exception e)
            {
                if (IsHandleableFileException(e))
                {
                    SendErrorMessage(e.Message);
                }
                else
                {
                    throw;
                }
            }

            Notify();
        }