[Free] 2017(Sep) EnsurePass Pass4sure GIAC GSSP-NET-CSHARP Dumps with VCE and PDF 231-240

EnsurePass
2017 Sep GIAC Official New Released GSSP-NET-CSHARP
100% Free Download! 100% Pass Guaranteed!
http://www.EnsurePass.com/GSSP-NET-CSHARP.html

GIAC GIAC Secure Software Programmer – C#.NET

Question No: 231 – (Topic 2)

You work as a Software Developer for ABC Inc. The Company uses the .NET Framework as its application development platform. You have created a class to represent a stop light. The stop light can be red, green, or blue. Which of the following elements would you use to simplify how developers defined the value?

  1. Structure

  2. Delegate

  3. Enumeration

  4. Interface

Answer: C

Question No: 232 – (Topic 2)

Patrick works as a Software Developer for BlueWell Inc. He develops an ASP.NET application

named App1 using Visual Studio .NET. The application displays employee registration form on the company#39;s Web site. The form contains the following fields:

l First Name l Last Name

l Date of Birth l E-mail

The application contains a TextBox control for each field. Patrick wants the application to provide a user-defined error message whenever an employee makes a wrong entry on the form. Patrick uses a CustomValidator validation control in the application. Which of the following properties is mandatory if the CustomValidator control is used to validate a user input data entry?

  1. EnableViewState

  2. IsValid

  3. EnableTheming

  4. ErrorMessage

Answer: B

Question No: 233 – (Topic 2)

Richard works as a Software Developer for BlueWell Inc. He is writing a component that will be shared by multiple applications. He wants to install the component in the GAC (Global Assembly Access) To install a component in the GAC, he requires to provide a strong name to the component. Which of the following tools will he use to accomplish this task?

  1. Al.exe

  2. Sn.exe

  3. Cert2spc.exe

  4. Signcode.exe

  5. Gacutil.exe

Answer: B

Question No: 234 – (Topic 2)

Maria works as a Software Developer for ManSoft Inc. She develops an application using Visual Studio .NET 2005. Maria wants to ensure that only employees of the Accounts department can view the application. Therefore, she decides to change the configuration settings in the Web.config file.

What will Maria do to accomplish the task?

  1. Add the lt;authorizationgt; element in the Web.config file. Then add the lt;allow users=quot;Accountsquot; /gt; attribute in the element.

  2. Add the lt;authenticationgt; element in the Web.config file.

  3. Add the lt;authorizationgt; element in the Machine.config file. Then add the lt;allow roles=quot;Accountsquot; /gt; attribute in the element.

  4. Add the lt;authorizationgt; element in the Web.config file.

Answer: B

Question No: 235 – (Topic 2)

You work as a Windows Application Developer for ABC Inc. The company uses Visual Studio .NET 2008 as its application development platform. You create a Windows Forms application using .NET Framework 3.5. You use LINQ expressions to read a list of employees from the following XML file:

lt;employeesgt;

lt;employee id=quot;135quot; birthDate=quot;5/01/1968quot;gt; Sam Paul lt;/employeegt;

lt;employee id=quot;122quot; birthDate=quot;3/05/1988quot;gt; Kelly Smith lt;/employeegt;

lt;employee id=quot;044quot; birthDate=quot;8/24/1990quot;gt; Joe Healy lt;/employeegt;

lt;employee id=quot;582quot; birthDate=quot;6/15/1974quot;gt; Matt Hardy lt;/employeegt;

lt;employee id=quot;275quot; birthDate=quot;2/07/2004quot;gt; Tom Altar lt;/employeegt;

lt;employee id=quot;144quot; birthDate=quot;9/23/1946quot;gt; Jeff Hay lt;/employeegt;

lt;employee id=quot;444quot; birthDate=quot;5/15/1947quot;gt; Kim Shane lt;/employeegt;

lt;employee id=quot;243quot; birthDate=quot;4/24/1980quot;gt; Mike Ray lt;/employeegt;

lt;employee id=quot;363quot; birthDate=quot;8/14/1975quot;gt; Allen Ryan lt;/employeegt;

lt;employee id=quot;473quot; birthDate=quot;1/15/1979quot;gt; Jackline Beneath lt;/employeegt;

lt;employee id=quot;713quot; birthDate=quot;9/09/1985quot;gt; Adam Ford lt;/employeegt;

lt;employee id=quot;032quot; birthDate=quot;5/04/1990quot;gt; Mike Tyson lt;/employeegt;

lt;/employeesgt;

You are required to obtain a list of names of employees who are 23 years or older. Which of the following code segments will you use?

  1. XDocument employees = XDocument.Load(quot;Employees.xmlquot;);

    var results = from c in employees Descendants() where ((DateTime)c.Attribute (quot;birthDatequot;)).AddYears(23) lt; DateTime.Now

    select new { FullName = c.Value };

  2. XDocument employees = XDocument.Load(quot;Employees.xmlquot;);

    var results = from c in employees Descendants(quot;employeequot;) where ((DateTime)c.Attribute (quot;birthDatequot;)).AddYears(23) lt; DateTime.Now

    select c Attribute(quot;Namequot;);

  3. XDocument employees = XDocument.Load(quot;Employees.xmlquot;);

    var results = from c in employees Descendants(quot;employeequot;) where ((DateTime)c.Attribute (quot;birthDatequot;)).AddYears(23) lt; DateTime.Now

    select c Element(quot;employeequot;);

  4. XDocument employees = XDocument.Load(quot;Employees.xmlquot;);

var results = from c in employees Descendants(quot;employeequot;) where ((DateTime)c.Attribute (quot;birthDatequot;)).AddYears(23) lt; DateTime.Now

select new { FullName = c.Value };

Answer: D

Question No: 236 – (Topic 2)

Smith works as a Software Developer for ABC Inc. He creates an application using Visual

Studio .NET 2005. The application displays quot;Welcome to ABCquot; on the top-left corner of a form. He writes the following code:

StringBuilder strbuild1 = new StringBuilder(20);

strbuild1.Append(quot;#39;Welcomequot;); strbuild1.Append(quot; quot;); strbuild1.Append(quot;toquot;); strbuild1.Append(quot; quot;); strbuild1.Append(quot;ABC#39;quot;);

string str1 = strbuild1.ToString(); Console.WriteLine(str1); Console.ReadLine();

What is the main purpose of using StringBuilder object in the application?

  1. To append a specified string to the end of the StringBuilder object.

  2. To concatenate two or more different set of strings or a set of Unicode characters.

  3. To create dynamic or mutable strings.

  4. To convert a value of the StringBuilder object to the String object.

    Answer: C

    Question No: 237 – (Topic 2)

    Allen works as a Software Developer for ABC Inc. He develops a Windows application. He adds a form to the application named Form1, which contains a Label control named Label1. A text file named File1.txt contains a list of products. File1.txt is located in the application directory. Each product name is listed in a new line in File1.txt. Allen wants to retrieve a list of products from File1.txt and display it in Label1. He adds the following code to the application:

    1. StreamReader Reader1 = new StreamReader((Stream)File.OpenText(Server.MapPath (quot;File1.txtquot;)));

    2. Stream MyStream;

    3. string InputString;

    4. // Insert statement here.

    5. while (InputString != null)

6. {

  1. Label1.Text = String.Format(quot;{0}{1}quot;, Label1.Text, InputString);

  2. Reader1.ReadLine(); 9. }

10. Reader1.Close();

Which of the following statements will Allen add at line 4 to accomplish the task?

  1. InputString = Reader1.ReadLine();

  2. InputString = Reader1.BaseStream.ToString();

  3. InputString = MyStream.ToString();

  4. InputString = MyStream.Read(b,0,Byte1.Length).ToString();

Answer: A

Question No: 238 – (Topic 2)

You work as Enterprise Application Developer in SunInfo Inc. The company uses Microsoft

.NET Framework 3.5. You design an application. You are required to execute queries against a collection and file directories. Which of the following data access technologies will you use to accomplish the task?

  1. LINQ to Objects

  2. LINQ to Data Services

  3. LINQ to XML

  4. LINQ to DataSets

Answer: A

Question No: 239 – (Topic 2)

You work as a Software Developer for Mansoft Inc. The company uses Visual Studio .NET as its application development platform. You create an application named ExceptionHandling using .NET Framework. You write code and execute it, but it causes an error. Now, you want to find out where the exception has occurred.

Which of the following properties of the exception class will you use to accomplish the

task?

  1. Source

  2. Message

  3. Data

  4. StackTrace

Answer: D

Question No: 240 – (Topic 2)

You work as a Software Developer for ABC Inc. The company uses Visual Studio .NET as its application development platform. You are creating an application using the .NET Framework. You are required to call an unmanaged method from your managed code with the help of platform invoke services. What will you do to accomplish this task?

  1. 1. Export a type library for your managed code

  2. 1. Import a type library as an assembly

    2. Create instances of COM object

  3. 1. Register your assembly by using COM

    2. Reference your managed code from COM

  4. 1. Create a class to hold DLL methods

  1. Create prototype methods with managed code

    Answer: D

    100% Free Download!
    Download Free Demo:GSSP-NET-CSHARP Demo PDF
    100% Pass Guaranteed!
    Download 2017 EnsurePass GSSP-NET-CSHARP Full Exam PDF and VCE

    EnsurePass ExamCollection Testking
    Lowest Price Guarantee Yes No No
    Up-to-Dated Yes No No
    Real Questions Yes No No
    Explanation Yes No No
    PDF VCE Yes No No
    Free VCE Simulator Yes No No
    Instant Download Yes No No

    2017 EnsurePass IT Certification PDF and VCE