public class VAInline
{
enum status : uint
{
BalancedPower = 444,
}
public void main()
{
string statusInfo = VA.GetText("statusPips") ?? "";
int pipsSectionStart = statusInfo.IndexOf("\"Pips") + 8;
if (pipsSectionStart == 7)
{
VA.WriteToLog("Error getting status pips: '\"Pips:\"' section not found", "red");
VA.SetText("statusPips", "");
return;
}
int pipsSectionEnd = statusInfo.IndexOf(',', pipsSectionStart);
string pipsNumber = statusInfo.Substring(pipsSectionStart, pipsSectionEnd - pipsSectionStart);
int pipsInt;
Int32.TryParse(pipsNumber, out pipsInt);
status pips = (status)pipsInt;
VA.SetText("statusPips", pips.ToString());
}
}
Once again I am starting over, not sure what I am doing wrong here