Article ID: 929187 - Last Review: November 28, 2007 - Revision: 1.25

MCTS Self-Paced Training Kit (Exam 70-526): Microsoft .NET Framework 2.0 Windows-Based Client Development comments and corrections part 1

On This Page

SUMMARY

This article contains comments, corrections, and information about known errors relating to the Microsoft Press book MCTS Self-Paced Training Kit (Exam 70-526): Microsoft .NET Framework 2.0 Windows-Based Client Development, 978-0-7356-2333-0.Additional comments and corrections are available in 949738 (http://support.microsoft.com/kb/949738) .

The following topics are covered:

  • CD-ROM: Missing files needed for Lesson 4 in Chapter 6
  • CD-ROM: "ImageIndex" should be "ImageList"
  • CD-ROM: "composite" should be "custom"
  • CD-ROM: == should be !=
  • CD-ROM: Readiness Review answer incorrectly marked correct
  • CD-ROM: Readiness Review incorrect answer marked as correct
  • CD-ROM: Readiness Review correct answer marked as incorrect
  • CD-ROM: Print should be PrintPage
  • Page 19: Property Grid used in place of Toolbox
  • Pages 22 and 23: Incorrect code in C# answers
  • Page 25: Select should be Double-click
  • Page 31: TopBottom should be replaced with TopDown
  • Page 33: Column numbering stated to begin at 1 rather than 0
  • Page 38: the words False and True should be reversed
  • Page 43: True missing from code sample
  • Page 44: The word "on" in missing from answer B to question 3
  • Page 53: TabOrder should be replaced with TabIndex
  • Page 56: spacing should be alignment
  • Page 69: MouseClickEventArgs should be replaced with MouseEventArgs
  • Page 75: right should be left
  • Page 85: $12,345.00 should be $12,345.67
  • Page 96: MultiSelect should be MultiExtended
  • Page 97: Single should be One
  • Page 98: Multiple errors in Table 3-2
  • Page 99: MultiSelect should be MultiExtended
  • Page 102: ListBox1.IndexOf should be ListBox1.Items.IndexOf
  • Page 109: null should be -1
  • Page 111: Incorrect description for Parent property in Table 3-7
  • Page 111: Incorrect description for PrevNode property in Table 3-7
  • Page 129: "IndexKey" should be "ImageKey"
  • Page 132: "ImageIndex" should be "ImageList"
  • Page 138: Incorrect character used in Size property
  • Page 154: containers should be panels
  • Page 156: Sample BMP files not located on Companion CD
  • Page 162: Incorrect capitalization in the word Flow
  • Page 164: "enabled" should be "displayed"
  • Page 165: "FileToolStripMenuItem" should be "fileToolStripMenuItem"
  • Page 168: "UnChecked" should be "Unchecked"
  • Page 183: "event" should be "method"
  • Page 189: Incorrect operator used in C# Step 2
  • Page 196: "MergeItem" should be "MergeAction"
  • Page 203: "State" property includes incorrect description
  • Page 206: Missing characters in C# code sample
  • Page 233: Invalid character in Button 3 property names
  • Page 236, Question 1: Answer concerning error range 20-29 is incorrect
  • Page 257: "DML" used in place of "DDL"
  • Page 260: "DDL" used in place of "DML"
  • Page 261: "Figure 6-2" should be "Table 6-5"
  • Page 262: Missing restriction in Table 6-6
  • Page 263: Missing quotation in C# code
  • Page 263: Wrong loop end in C# code
  • Page 275: SqlParameter used in place of SqlCommand
  • Page 285: Stored procedures missing in Northwind Database

MORE INFORMATION

CD-ROM: Missing files needed for Lesson 4 in Chapter 6

The files Customers.fmt and NorthwindCustomers.txt that are needed to complete Lesson 4 in Chapter 6 on page 310 are not located on CD as is stated in the Training Kit.

The following file is available for download from the Microsoft Download Center:

Customers.exe (http://download.microsoft.com/download/1/1/b/11b03076-8ae8-411b-a3cb-9741746ba06f/customers.exe)

For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 (http://support.microsoft.com/kb/119591/en-us/)

How to Obtain Microsoft Support Files from Online Services Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

CD-ROM: "ImageIndex" should be "ImageList"

One of the Readiness Review assessment questions contains an answer with an incorrect C# component.

The question reads:
"Which of the following code examples correctly associates an image from an ImageList component with a Button control? Assume an ImageList component named ImageList1 and a Button control named Button1. (Choose all that apply.)"

In the correct answer change:
Button1.ImageList = ImageList1
Button1.ImageKey = "myImage"

// C#
button1.ImageIndex = imageList1;
button1.ImageKey = "myImage";

To:
Button1.ImageList = ImageList1
Button1.ImageKey = "myImage"

// C#
button1.ImageList = imageList1;
button1.ImageKey = "myImage";


CD-ROM: "composite" should be "custom"

In the Readiness Review assessment, Question 27 (526P_6.1.7_01) uses an incorrect control.

Change:
"You are creating a composite control. You want to provide a transparent background color. How can you do this? (Choose all that apply.)"

To:
"You are creating a custom control. You want to provide a transparent background color. How can you do this? (Choose all that apply.)"

CD-ROM: == should be !=

One of the Readiness Review assessment questions contains an answer with an incorrect C# component.

The question reads:
"You created a Windows Forms application. The application performs long-running operations, and you create a BackgroundWorker object named BackgroundWorker1. You create a method named BackgroundWorker1_RunWorkerCompleted to respond when the process has completed successfully, ended in an error, or been cancelled by the user. The method declaration is:"

In the third answer, the first line contains a "==" symbol rather than a "!=" symbol.

Change:
if (e.Error == null)

To:
if (e.Error != null)

CD-ROM: Readiness Review answer incorrectly marked correct

One of the questions on the Readiness Review Assessment has an incorrect answer marked as correct.

The question reads:
"You are creating a Windows Forms application that will be deployed to a kiosk environment. The application will be used by thousands of people, including users who have unique visual requirements such as using High Contrast mode.

While developing your application, which of the following guidelines should you follow to ensure that the application will work well in High Contrast mode? (Choose all that apply.)"

The following answer should be incorrect:
"Convey by visual cues or sound any information that is conveyed through color."

CD-ROM: Readiness Review incorrect answer marked as correct

On the Readiness Review Assessment, one of the questions has an incorrect answer marked as correct.

The question reads:
"You create a Windows Forms application. The application acts as a Web services client. Typically, the servers respond quickly; however, one specific type of transaction requires multiple different Web services requests and may take ten or twenty seconds to complete. To enable your application to continue to respond to user input, you implement a BackgroundWorker component to perform the Web services requests.

You want to display a progress bar that regularly updates to inform the user of the progress. What is the best way to do this?"

The following answer should be marked as incorrect:
"From within your form, create a timer that elapses every second. Respond to the timer by calling BackgroundWorker.ProgressChanged. Examine the returned value to update the progress bar. "

CD-ROM: Readiness Review correct answer marked as incorrect

On the Readiness Review Assessment, one of the questions has an correct answer marked as incorrect.

The question reads:
"You want to specify a custom icon for your application's shortcut on the Start menu. Which file types can you choose to specify an icon? (Choose all that apply.)"

The following answer should be marked as correct:
".ico"

CD-ROM: Print should be PrintPage

In the Readiness Review software, one of the andswers to one of the questions refers to Print rather than PrintPage. The question reads:
"You are creating a Windows Forms application that enables users to create a document and print it. What is the simplest way to create a standard Print Preview dialog box?"

Change:
"Implement an event handler for the PrintDocument.Print event. Then, create an instance of PrintPreviewDialog, and use your PrintDocument instance to define PrintPreviewDialog.Document. Call PrintPreviewDialog.ShowDialog."

To:
"Implement an event handler for the PrintDocument.PrintPage event. Then, create an instance of PrintPreviewDialog, and use your PrintDocument instance to define PrintPreviewDialog.Document. Call PrintPreviewDialog.ShowDialog."

Page 19: Property Grid used in place of Toolbox

On page 19, the first sentence of Step 4 reads:

"Drag a Button from the Property Grid to the upper left-hand corner of the form."

It should read:

"Drag a Button from the Toolbox to the upper left-hand corner of the form."

Pages 22 and 23: Incorrect code in C# answers

On pages 22 and 23, the aPath line in the C# section of every answer to question 2 reads:

aPath.AddEllipse(0, 0, Me.Width, Me.Height);

It should read:

aPath.AddEllipse(0, 0, this.Width, this.Height);


Page 25: Select should be Double-click

On page 25, the third bullet point is incorrect.

Change:
"Select a control in the Toolbox and double-click the form."

To:
"Double-click a control in the Toolbox."

Page 31: TopBottom should be replaced with TopDown

On page 31, the third sentence of the FlowDirection description of Table 1-6 reads:

"Can be set to LeftToRight, RightToLeft, TopBottom, or BottomUp."

It should read:

"Can be set to LeftToRight, RightToLeft, TopDown, or BottomUp."

Page 33: Column numbering stated to begin at 1 rather than 0

On page 33, the first two sentences of the fourth paragraph read:

"Columns in a TableLayoutPanel are numbers starting at 1, while rows start at 0. Thus, the example shown above adds aButton to the cell in column 3 at row 3, which is actually the 3rd column and the 4th row the user sees."

It should read:

"Columns and rows in a TableLayoutPanel are numbers starting at 0. Thus, the example shown above adds aButton to the cell in column 3 at row 3, which is actually the 4th column and the 4th row the user sees."

Page 38: the words False and True should be reversed

On page 38, the last two sentences in the second to the last paragraph read:

"Note that you cannot set both of these controls to False. For example, if you set Panel1Collapsed to False when the Panel2Collapsed is already set to False, Panel2Collapsed will be set to True."

They should read:

"Note that you cannot set both of these controls to True. For example, if you set Panel1Collapsed to True when the Panel2Collapsed is already set to True, Panel2Collapsed will be set to False."

Page 43: True missing from code sample

On page 43, Answer C to question 1 is missing a parameter.

Change:
' VB
FLPanel1.SetFlowBreak(aButton)
// C#
FLPanel1.SetFlowBreak(aButton);


To:
' VB
FLPanel1.SetFlowBreak(aButton, True)
// C#
FLPanel1.SetFlowBreak(aButton, true);


Page 44: The word "on" in missing from answer B to question 3

On page 44, answer B to question 3 reads:

"Select a control in the Toolbox and draw the form with the mouse."

It should read:

"Select a control in the Toolbox and draw on the form with the mouse."

Page 53: TabOrder should be replaced with TabIndex

On page 53, the 5th property in Tabel 2-1 reads:

"TabOrder"

It should read:

"TabIndex"

Page 56: spacing should be alignment

On page 56, step 3 of the "To adjust control alignment with the Layout toolbar" section refers to spacing instead of alignment.

Change:
"Adjust the control spacing by clicking the appropriate button."

To:
"Adjust the control alignment by clicking the appropriate button."

Page 69: MouseClickEventArgs should be replaced with MouseEventArgs

On page 69, the first sentence of the 2nd paragraph reads:

"One of the arguments for the Button.MouseDown event handler is an instance of MourseClickEventArgs."

It should read:

"One of the arguments for the Button.MouseDown event handler is an instance of MourseEventArgs."

The last sentence of the 2nd paragraph reads:

"Table 2-3 describes the properties of the MourseClickEventArgs class."

It should read:

"Table 2-3 describes the properties of the MourseEventArgs class."

The first sentence of the 3rd paragraph reads:

"Using the values exposed by the MouseClickEventArgs instance, you can determine the button that was clicked and the position of the mouse wheel."

It should read:

"Using the values exposed by the MouseEventArgs instance, you can determine the button that was clicked and the position of the mouse wheel."

Page 75: right should be left

On page 75, the answer to Quick Check 1 references the right button rather than the left button.

Change:
"The Click event responds to the right button click, and the MouseDown event can be used to respond to other button clicks."

To:
"The Click event responds to the left button click, and the MouseDown event can be used to respond to other button clicks."

Page 85: $12,345.00 should be $12,345.67

On page 85, the ammount indicated in the Displayed Text column of the $99,999.00 row is incorrect.

Change:
"$12,345.00 – Note that the actual currency symbol, thousands separator, and decimal separator will be determined by the control’s FormatProvider."

To:
"$12,345.67 – Note that the actual currency symbol, thousands separator, and decimal separator will be determined by the control’s FormatProvider."

Page 96: MultiSelect should be MultiExtended

On page 96, the description of SelectedItem in Table 3-1 references MultiSelect in place of MultiExtended.

Change:
"Returns the selected item or, if the SelectionMode property is set to MultiSimple or MultiSelect, returns any selected item."

To:
"Returns the selected item or, if the SelectionMode property is set to MultiSimple or MultiExtended, returns any selected item."

Page 97: Single should be One

On page 97, the second sentence of the description of SelectionMode in Table 3-1 is incorrect.

Change:
"Can be set to None, Single, MultiSimple, or MultiExtended. MultiSimple allows the selection of multiple objects, and MultiExtend allows the use of the Shift and Ctrl keys when making multiple selections."

To:
"Can be set to None, One, MultiSimple, or MultiExtended. MultiSimple allows the selection of multiple objects, and MultiExtend allows the use of the Shift and Ctrl keys when making multiple selections."

Page 98: Multiple errors in Table 3-2

On page 98, the SelectedIndex, SelectedItem, and ValueMember descriptions are incorrect.

Change:
"SelectedIndex Gets the index of the selected item, or, if the SelectionMode property is set to MultiSimple or MultiSelect, returns any selected index.

SelectedItem Returns the selected item, or, if the SelectionMode property is set to MultiSimple or MultiSelect, returns any selected item.

ValueMember Indicates the data member that will provide the values for the ListBox."

To:
"SelectedIndex Gets the index of the selected item.

SelectedItem Returns the selected item.

ValueMember Indicates the data member that will provide the values for the ComboBox."

Page 99: MultiSelect should be MultiExtended

On page 99, the SelectedIndex and SelectedItem descriptions in Table 3-3 are incorrect.

Change:
"SelectedIndex Gets the index of the selected item, or, if the SelectionMode property is set to MultiSimple or MultiSelect, it can return any selected index.

SelectedItem Returns the selected item, or, if the SelectionMode property is set to MultiSimple or MultiSelect, it can return any selected item."

To:
"SelectedIndex Gets the index of the selected item, or, if the SelectionMode property is set to MultiSimple or MultiExtended, it can return any selected index.

SelectedItem Returns the selected item, or, if the SelectionMode property is set to MultiSimple or MultiExtended, it can return any selected item."

Page 102: ListBox1.IndexOf should be ListBox1.Items.IndexOf

On page 102, the first code sample is incorrect.

Change:
"' VB
Dim anIndex As Integer
anIndex = ListBox1.IndexOf("A String")

// C#
int anIndex;
anIndex = listBox1.IndexOf("A String");"

To:
"' VB
Dim anIndex As Integer
anIndex = ListBox1.Items.IndexOf("A String")

// C#
int anIndex;
anIndex = listBox1.Items.IndexOf("A String");"


Page 109: null should be -1

On page 109, the second sentence of the ImageKey property in Table 3-6 contains an incorrect property.

Change:
"If the ImageKey property is set, the ImageIndex property is set to null."

To:
"If the ImageKey property is set, the ImageIndex property is set to -1."

Page 111: Incorrect description for Parent property in Table 3-7

On page 111, the description for the Parent property in Table 3-7 is incorrect.

Change:
"Returns the parent node of the current node. If the current node is a root node in the TreeView, accessing this property will throw a NullReferenceException."

To:
"Returns the parent node of the current node. If the current node is a root node in the TreeView, accessing this property will return null."

Page 111: Incorrect description for PrevNode property in Table 3-7

On page 111, the description for the PrevNode property in Table 3-7 is incorrect.

Change:
"Returns the previous node."

To:
"Returns the previous sibling tree node."

Page 129: "IndexKey" should be "ImageKey"

On page 129, the third sentence in Quick Check Answer # 2 contains an invalid property.

Change:
"You can set the ImageList property of the controls on a form to an instance of the ImageList and then set either the ImageIndex or the IndexKey property to specify the image."

To:
"You can set the ImageList property of the controls on a form to an instance of the ImageList and then set either the ImageIndex or the ImageKey property to specify the image."

Page 132: "ImageIndex" should be "ImageList"

On page 132, Question 3 Answer D contains an incorrect C# component.

Change:
D.
' VB
Button1.ImageList = ImageList1
Button1.ImageKey = "myImage"

// C#
button1.ImageIndex = imageList1;
button1.ImageKey = "myImage";

To: D.
' VB
Button1.ImageList = ImageList1
Button1.ImageKey = "myImage"

// C#
button1.ImageList = imageList1;
button1.ImageKey = "myImage";

Page 138: Incorrect character used in Size property

On page 138, Step 2 of Exercise 1 uses an incorrect character for the Size property.

Change:
"2. In the Properties window for Form1, set the Size property to 600,400."

To:
"2. In the Properties window for Form1, set the Size property to 600;400."

Page 154: containers should be panels

On page 154, the last sentence of the second paragraph contains and incorrect Tool Strip type.

Change:
"This results in the ToolStripContainer filling the entire form and having tool strip containers available on all sides."

To:
"This results in the ToolStripContainer filling the entire form and having tool strip panels available on all sides."

Page 156: Sample BMP files not located on Companion CD

On page 156, Lab 1, Exercise 1, Step 7 states that the following image files can be found in the code folder on the companion CD: Back.bmp, Forward.bmp, Go.bmp, and Stop.bmp.

The files are not located on the CD. It is available for download from the Microsoft Download Center:

images.exe (http://download.microsoft.com/download/4/e/a/4ea02439-ab9f-40be-a47d-54bf949ea28b/images.exe)

For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:

119591 (http://support.microsoft.com/kb/119591/en-us/) How to Obtain Microsoft Support Files from Online Services

Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.

Page 162: Incorrect capitalization in the word Flow

On page 162, in the description for the property LayoutStyle the F in "HorizontalStackWithOverFlow" and "Vertical- StackWithOverFlow" should not be capitalized.

Change:
"A value of HorizontalStackWithOverFlow indicates that items are stacked horizontally and overflow as needed. Vertical- StackWithOverFlow stacks items vertically and overflows as needed."

To:
"A value of HorizontalStackWithOverflow indicates that items are stacked horizontally and overflow as needed. Vertical- StackWithOverflow stacks items vertically and overflows as needed."

Page 164: "enabled" should be "displayed"

On page 164, the description for the ShowShortcutKeys property is incorrect.

Change:
"Indicates whether shortcut keys are enabled."

To:
"Indicates whether shortcut keys are displayed."

Page 165: "FileToolStripMenuItem" should be "fileToolStripMenuItem"

On page 165, in the second sentence at the top of the page the variable FileToolStripMenuItem has an incorrect capitalization.

Change:
"For example, if you created a File menu item, the default name would be FileToolStripMenuItem."

To:
"For example, if you created a File menu item, the default name would be fileToolStripMenuItem."

Page 168: "UnChecked" should be "Unchecked"

On page 168, the first complete sentence at the top of the page contains an incorrect capitalization in the word UnChecked.

Change:
"The CheckState property on the other hand, indicates the actual state of the menu item and will return either CheckState.Checked,CheckState.UnChecked, or Checkstate.Indeterminate."

To:
"The CheckState property on the other hand, indicates the actual state of the menu item and will return either CheckState.Checked,CheckState.Unchecked, or Checkstate.Indeterminate."

Page 183: "event" should be "method"

On page 183, the second sentence in Step 4 incorrectly uses the word "event".

Change:
"Choose the event you created in the Code Editor."

To:
"Choose the method you created in the Code Editor."

Page 189: Incorrect operator used in C# Step 2

On page 189, Step 2 in the C# section uses an incorrect operator.

Change:
"2. You can remove an event handler at run time by using the =- operator, as shown here:"

To:
"2. You can remove an event handler at run time by using the -= operator, as shown here:"

Page 196: "MergeItem" should be "MergeAction"

On page 196, the first bullet point under Suggested Practices contains an incorrect property.

Change:
"Create toolbars with similar members and practice merging them together, changing the MergeIndex and MergeItem properties of each tool strip item."

To:
"Create toolbars with similar members and practice merging them together, changing the MergeIndex and MergeAction properties of each tool strip item."

Page 203: "State" property includes incorrect description

On page 203, in Table 5-2 the description of the property "State" is incorrect and needs to be changed.

Change:
"Read only. Gets a string that describes the state of the connection."

To:
"Read only. Gets a combination of System.Data.ConnectionState values that describes the state of the connection."

Page 206: Missing characters in C# code sample

On page 206, the C# code sample near the top of the page is missing closing characters and is incomplete.

Change:
// C#
private OracleConnection ConnectionToOracle = new OracleConnection
("Data Source=Oracle8i;Integrated Security=yes;
To:
// C#
private OracleConnection ConnectionToOracle = new OracleConnection
("Data Source=Oracle8i;Integrated Security=yes");

Page 233: Invalid character in Button 3 property names

On page 233, the property names in Button 3 contain an incorrect character that needs to be removed.

Change:
Button3:
<Name = ConnectToInvalidDatabaseButton
<Text = Connect to invalid database

To:
Button3:
Name = ConnectToInvalidDatabaseButton
Text = Connect to invalid database

Page 236, Question 1: Answer concerning error range 20-29 is incorrect

On page 236, answers C and D of Question 1 reads:

"C. Errors with a severity level of 20 through 29
D. Errors with a severity level of 30 or greater"

They should read:
"C. Errors with a severity level of 20 through 25
D. Errors with a severity level of 26 or greater"

Page 257: "DML" used in place of "DDL"

On page 257, the first sentence of the second paragraph reads:

"To execute commands that run DML actions (Data Manipulation Language), create commands that run SQL statements and call the ExecuteNonQuery method of the command."

It should read:

"To execute commands that run DDL actions (Data Definition Language), create commands that run SQL statements and call the ExecuteNonQuery method of the command."

Page 260: "DDL" used in place of "DML"

On page 260, the third paragraph reads:

"Each .NET Framework Data Provider Command object exposes three main execution methods that can be used to return data, update data, call stored procedures and functions, and so on, or perform catalog operations such as executing data definition language (DDL) commands against a data source."

It should read:

"Each .NET Framework Data Provider Command object exposes three main execution methods that can be used to return data, update data, call stored procedures and functions, and so on, or perform catalog operations such as executing data manipulation language (DML) commands against a data source."

Page 261: "Figure 6-2" should be "Table 6-5"

On page 261, the first sentencen in the first paragraph contains an incorrect reference to Figure 6-2.

Change:
"In addition to the execution commands listed in Figure 6-2, an additional set of commands are specifically used for asynchronous calls to a database."

To:
"In addition to the execution commands listed in Table 6-5, an additional set of commands are specifically used for asynchronous calls to a database."

Page 262: Missing restriction in Table 6-6

On page 262, on Table 6-6 the commands BeginExecuteXMLReader and EndExecuteXMLReader are missing the note (SQLCommand only).

Change:
BeginExecuteXmlReader

To:
BeginExecuteXmlReader
(SQLCommand only)

Change:
EndExecuteXMLReader

To:
EndExecuteXMLReader
(SQLCommand only)

Page 263: Missing quotation in C# code

On page 263, the 6th line down in the C# code is missing a quotation mark in the definition of command1.

Change:
SqlCommand command1 = new SqlCommand("WAITFOR DELAY '00:00:05'; " +
	Select * From [Order Details]", NorthWindConnection);

To:
SqlCommand command1 = new SqlCommand("WAITFOR DELAY '00:00:05'; " +
	"Select * From [Order Details]", NorthWindConnection);

Page 263: Wrong loop end in C# code

On page 263, the 16th line down in the C# code sample contains an incorrect loop end.

Change:
for (int i = 0; i< reader.FieldCount - 1; i++)

To:
for (int i = 0; i< reader.FieldCount; i++)

Page 275: SqlParameter used in place of SqlCommand

On page 275, the first sentence of the paragraph under "Adding Parameters to Command Objects" reads:

"Command objects have a Parameters property that represents a collection of parameters for that command (for example, the SqlParameter.Parameters property)."

It should read:

"Command objects have a Parameters property that represents a collection of parameters for that command (for example, the SqlCommand.Parameters property)."

Page 285: Stored procedures missing in Northwind Database

On page 285, in order to complete Exercise 3 you might have to create stored procedures in the Northwind Database for Get Freight Cost and Get Contact Name.

To create the GetFreightCost stored procedure use the following code:

CREATE PROCEDURE GetFreightCost
@ORDERID INT,
@Freight MONEY OUTPUT
AS
SELECT @Freight = Freight FROM Orders WHERE OrderID = @OrderID

To create the GetContactName stored procedure use the following code:

CREATE PROCEDURE GetContactName
@Name NVARCHAR(40) OUTPUT
AS
SELECT @Name = ContactName FROM Customers WHERE CompanyName = @Name


Microsoft Press is committed to providing informative and accurate books. All comments and corrections listed above are ready for inclusion in future printings of this book. If you have a later printing of this book, it may already contain most or all of the above corrections.

Keywords: 
KB929187

Note: This article is from Microsoft Knowledage Base


How we have helped PC users like you

In the News: Read More In ...

Related problems posted by other users

more...