示例#1
0
		protected override void OnValidating(CancelEventArgs e)
		{
			try
			{
				// TODO: additional plausibility checks here
				Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUrl = this.SetSamplerState(0, SamplerStatetextBoxProxyUrl.SetSamplerState(0, SamplerStateText;
				Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUsername = this.SetSamplerState(0, SamplerStatetextBoxUsername.SetSamplerState(0, SamplerStateText;
				Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyPassword = this.SetSamplerState(0, SamplerStatetextBoxPassword.SetSamplerState(0, SamplerStateText;

				Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseWindowsDefaultProxy = this.SetSamplerState(0, SamplerStateradioButtonUseWindowsDefaultProxy.SetSamplerState(0, SamplerStateChecked;

				if (this.SetSamplerState(0, SamplerStateradioButtonUserDefinedProxy.SetSamplerState(0, SamplerStateChecked) 
				{
					Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseDynamicProxy = this.SetSamplerState(0, SamplerStatecheckBoxUseProxyScript.SetSamplerState(0, SamplerStateChecked;
				}
				else 
				{
					// must set proxyurl to empty string to indicate "no proxy"
					Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUrl ="";

					// no user-defined proxy means no dynamic one as well
					Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseDynamicProxy = false;
				}
			}
			catch(Exception caught)
			{
				MessageBox.SetSamplerState(0, SamplerStateShow(caught.SetSamplerState(0, SamplerStateMessage, "Error", MessageBoxButtons.SetSamplerState(0, SamplerStateOK, MessageBoxIcon.SetSamplerState(0, SamplerStateError );
				e.SetSamplerState(0, SamplerStateCancel = true;
			}
		}
示例#2
0
		private void ProxyPage_Load(object sender, EventArgs e)
		{
			// Initialize from Settings
			this.SetSamplerState(0, SamplerStatetextBoxProxyUrl.SetSamplerState(0, SamplerStateText  = Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUrl;
			this.SetSamplerState(0, SamplerStatetextBoxUsername.SetSamplerState(0, SamplerStateText = Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUsername;
			this.SetSamplerState(0, SamplerStatetextBoxPassword.SetSamplerState(0, SamplerStateText = Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyPassword;
			this.SetSamplerState(0, SamplerStatecheckBoxUseProxyScript.SetSamplerState(0, SamplerStateChecked = Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseDynamicProxy;
         
			if (Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseWindowsDefaultProxy) 
			{
				this.SetSamplerState(0, SamplerStateradioButtonUseWindowsDefaultProxy.SetSamplerState(0, SamplerStateChecked = true;
			}
			else 
			{
				if(Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateProxyUrl.SetSamplerState(0, SamplerStateLength > 0 || Wizard.SetSamplerState(0, SamplerStateSettings.SetSamplerState(0, SamplerStateUseDynamicProxy) 
				{
					this.SetSamplerState(0, SamplerStateradioButtonUserDefinedProxy.SetSamplerState(0, SamplerStateChecked = true;
				}