闁衡偓閹増顥� (0) +1 閻犙嶆嫹 (0) +1 闂婎亷鎷� (0) +1
闁衡偓閹増顥戦柟瀛樺姇婵拷闁哄被鍎冲﹢鍛村绩閹増顥�>>

正在阅读:在C#中调用VBScript等脚本的实现在C#中调用VBScript等脚本的实现

2004-05-13 10:23 出处:PConline 作者:秋枫 责任编辑:linjixiong

  using System;

  using System.Drawing;

  using System.Collections;

  using System.ComponentModel;

  using System.Windows.Forms;

  using System.Data;

  namespace ZZ

  {

     public class Form1 : System.Windows.Forms.Form

     {

         private ScriptEngine scriptEngine;

         private System.Windows.Forms.CheckBox checkBoxAllowUI;

         private System.Windows.Forms.TextBox textBoxResult;

         private System.Windows.Forms.NumericUpDown numericUpDownTimeout;

         private System.Windows.Forms.TextBox textBoxCodeBody;

         private System.Windows.Forms.Button buttonRun;

         private System.Windows.Forms.Button buttonCancel;

         private System.Windows.Forms.ComboBox comboBoxScript;

         private System.Windows.Forms.TextBox textBoxParams;

         private System.Windows.Forms.RadioButton radioButtonEval;

         private System.Windows.Forms.RadioButton radioButtonRun;

         private System.Windows.Forms.TextBox textBoxMethodName;

         private System.ComponentModel.Container components = null;

         public Form1()

         {

              InitializeComponent();

              this.comboBoxScript.SelectedIndex = 0;

              this.scriptEngine = new ScriptEngine();

              this.scriptEngine.UseSafeSubset = true;

              this.scriptEngine.RunError += new RunErrorHandler(scriptEngine_RunError);


察看评论详细内容 我要发表评论
作者笔名 简短内容 发表时间
:

键盘也能翻页,试试“← →”键

关注我们

最新资讯离线随时看 聊天吐槽赢奖品
闁归潧顑嗗┃鈧悹浣告健濡拷闁搞儳鍋涢崺灞俱亜閸洖鍔�