2013微軟認(rèn)證考試練習(xí)題及答案(35)

字號(hào):

為大家收集整理了《2013微軟認(rèn)證考試練習(xí)題及答案(35)》供大家參考,希望對(duì)大家有所幫助!??!
    QUESTION 91
    You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
    You create a Web form in the application by using the following code fragment. (Line numbers are included for reference only.)
    01
    07
    08 09 runat="server" />
    10
    11 12 UpdateMode="Conditional" runat="server">
    13
    14
    15 16 Text="Submit" OnClick="Button_Handler" />
    17

    18
    19
    You plan to create a client-side script code by using ASP.NET AJAX.
    You need to ensure that while a request is being processed, any subsequent Click events on the btnSubmit Button control are suppressed.
    Which code fragment should you insert at line 10?
    A.
    B.
    C.
    D.
    Answer: C
    QUESTION 92
    You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
    You create a page that contains the following control.
    You write the following code segment in the code-behind file for the page.
    void LoadDate(object sender, EventArgs e) {
     if (IsPostBack) {
     calBegin.SelectedDate = (DateTime)ViewState["date"];
     }
    }
    void SaveDate(object sender, EventArgs e) {
    ViewState["date"] = calBegin.SelectedDate;
    }
    You need to ensure that the calBegin Calendar control maintains the selected date.
    Which code segment should you insert in the constructor of the page?
    A.this.Load += new EventHandler(LoadDate); this.Unload += new EventHandler(SaveDate);
    B.this.Init += new EventHandler(LoadDate); this.Unload += new EventHandler(SaveDate);
    C.this.Init += new EventHandler(LoadDate); this.PreRender += new EventHandler(SaveDate);
    D.this.Load += new EventHandler(LoadDate); this.PreRender += new EventHandler(SaveDate);
    Answer: D
    QUESTION 93
    You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
    You create a FormView control to access the results of a query.
    The query contains the following fields:
    EmployeID
    FirstNam
    LastNam
    The user must be able to view and update the FirstName field.
    You need to define the control definition for the FirstName field in the FormView control.
    Which code fragment should you use?
    A." />
    B." />
    C.’ />
    D.’ />
    Answer: C
    QUESTION 94
    You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
    You create a Web form by using ASP.NET AJAX.
    The Web form contains the following code fragment. (Line numbers are included for reference only.)
    01
    10
    11 12 runat="server" />
    13
    You need to create and initialize a client behavior named MyCustomBehavior by using the initComponents function. You also need to ensure that MyCustomBehavior is attached to the TextBox1 Textbox control.
    Which code segment should you insert at line 06?
    A.$create(MyCustomBehavior, null, null, null, ’TextBox1’);
    B.$create(MyCustomBehavior, null, null, null, $get(’TextBox1’));
    C.Sys.Component.create(MyCustomBehavior, ’TextBox1’, null, null, null);
    D.Sys.Component.create(MyCustomBehavior, $get(’TextBox1’), null, null, null);
    Answer: B
    QUESTION 95
    You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.
    You create the following controls:
    A composite custom control named MyControl.
    A templated custom control named OrderFormData.
    You write the following code segment to override the method named CreateChildControls() in the MyControl class. (Line numbers are included for reference only.)
    01 protected override void
    02 CreateChildControls() {
    03 Controls.Clear();
    04 OrderFormData oFData = new
    05 OrderFormData("OrderForm");
    06
    07 }
    You need to add the OrderFormData control to the MyControl control.
    Which code segment should you insert at line 06?
    A.Template.InstantiateIn(this); this.Controls.Add(oFData);
    B.Template.InstantiateIn(oFData); Controls.Add(oFData);
    C.this.TemplateControl = (TemplateControl)Template; -Can’t Remember All-???
    oFData.TemplateControl = (TemplateControl)Template;
    Controls.Add(oFData);
    D.this.TemplateControl = (TemplateControl)oFData; -Can’t Remember All-???
    Controls.Add(oFData);
    Answer: B