-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathScript.cs
35 lines (30 loc) · 927 Bytes
/
Script.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows;
using VMS.TPS.Common.Model.API;
[assembly: ESAPIScript(IsWriteable = true)]
namespace VMS.TPS
{
class Script
{
[MethodImpl(MethodImplOptions.NoInlining)]
public void Execute(ScriptContext scriptcontext)
{
if (scriptcontext.ExternalPlanSetup == null)
{
MessageBox.Show("No plan is open.", "Error");
return;
}
Thread.CurrentThread.CurrentCulture = new CultureInfo("en-US");
scriptcontext.Patient.BeginModifications();
EQD2Converter.MainWindow mainWindow = new EQD2Converter.MainWindow(scriptcontext);
mainWindow.ShowDialog();
}
}
}