public API_Blogger login(Credential credential)
    	{    	
    		if (credential == null)
    			credential = IE.askUserForUsernameAndPassword();      	
    		this.Credential = credential;
    		IE.open(LoginPage);     		
    		if (IE.url() == LoginPage && IE.title()== ExpectedTitle_LoginPage)
    		{
    			if (IE.hasButton("Sign in"))
    			{
    				IE.set_Value("Email",this.Credential.username());
    				IE.set_Value("Passwd",this.Credential.password());    			
    				IE.click("Sign in");    				   				   				   			
    			}
    		}
    		if (inDashBoard())
			{
				UserBlogMainPage =  IE.link("View Blog").url();
				"[BloggerAPI]: logged in as user :{0}".info(this.Credential.username());
				LoggedIn = true;
				return this;
			}
			this.Credential = null;
    		"[BloggerAPI]: an error occured during the login process".error();	
			return this;
    	}
		public API_AmazonEC2(Credential apiKey) 
		{
			DefaultRegion = "us-west-1";//"eu-west-1";
			if (apiKey.isNull())
				apiKey = ascx_AskUserForLoginDetails.ask();
			ApiKey = apiKey;
		}
        public Credential getAnswer()
        {
            HaveAnswer.WaitOne();

            var credential = new Credential();
            credential.UserName = UserName;
            credential.Password = Password;
            //"u:{0}".debug(credential.UserName);
            //"p:{0}".debug(credential.Password);
            return credential;
        }
		public void loadCredentialDetails(Credential credential)
		{
			UserName_TextBox.set_Text(credential.username());
			Password_TextBox.set_Text(credential.password());
		}
    	public static API_IE_CxWebClient login(this API_IE_CxWebClient cxClient, Credential credential)
    	{
			return cxClient.login(credential.UserName, credential.Password);
    	}