Online Access Free 070-516 Practice Test

Exam Code:070-516
Exam Name:TS: Accessing Data with Microsoft .NET Framework 4
Certification Provider:Microsoft
Free Question Number:196
Posted:Jun 01, 2026
Rating
100%

Question 1

You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4.0 to create an application.
The application uses the ADO.NET Entity Framework to manage customer and related order records.
You add a new order for an existing customer. You need to associate the Order entity with the Customer
entity.
What should you do?

Question 2

You use Microsoft .NET Framework 4.0 to develop an application that connects to a Microsoft SQL Server
200B database.
You populate a SqlDataAdapter by using the following code. (Line numbers are included for reference only.)
01 SqlDataAdapter dataAdapter1 = new SqlDataAdapter("SELECT * FROM
[BlogEntries] ORDER BY CreationDate", connection);
02 cmdBuilder = new SqlCommandBuilder(dataAdapter1);
03 dataAdapter1.Fill(BlogEntryDataSet, "BlogEntries");
04 ....
05 connection.Close();
You need to update the blog owner for all BlogEntry records. Which code segment should you insert at line 04?

Question 3

You add a table to the database to track changes to part names. The table stores the following row values:
-the username of the user who made the change
-a part ID
-the new part name
-a DateTime value
You need to ensure detection of unauthorized changes to the row values.
You also need to ensure that database users can view the original row values.

Question 4

You use Microsoft .NET Framework 4.0 to develop an application that exposes a WCF Data Services
endpoint.
The endpoint uses an authentication scheme that requires an HTTP request that has the following header
format.
GET /OData.svc/Products(1)
Authorization: WRAP access_token "123456789"
You add the following method to your DataService implementation.
01 protected override void OnStartProcessingRequest(ProcessRequestArgs args)
02 {
03 ....
04 }
You need to ensure that the method retrieves the authentication token. Which line of code should you use?

Question 5

You are adding a process to the application. The process performs the following actions:
1.Opens a ContosoEntities context object named context1.
2.Loads a Part object into a variable named part1.
3.Calls the Dispose() method on context1.
4.Updates the data in part1.
5.Updates the database by using a new ContosoEntities context object named context2.
You need to update the database with the changed data from part1. What should you do?

Add Comments

Your email address will not be published. Required fields are marked *

insert code
Type the characters from the picture.