Beruflich Dokumente
Kultur Dokumente
ICT Reviewer
Reviewer in ICT
Second Quarter
Whereas:
Expression - an expression that must evaluate to any of the elementary data type in
VB.Net, i.e., Boolean, Byte, Char, Date, Double, Decimal, Integer.
Expressionlist - list of expression clauses representing match values for expression.
Multiple expression clauses are separated by commas.
o Example of valid expression lists:
CASE 1 TO 5
CASE IS > 90
CASE 2, 4, 8
Sample Code:
Private Sub TextBox1_KeyPress(ByVal sender As Object, ByVal e As
System.Windows.Forms.KeyPressEventArgs) Handles TextBox1.KeyPress
If (e.KeyChar < "0" Or e.KeyChar > "9")
And e.KeyChar <> "."
And e.KeyChar <> ControlChars.Back Then
' cancel the key
e.Handled = True
End If
End Sub
DO {WHILE|UNTIL} LOOP
Use the While keyword in a looping condition to specify that the loop body should be
processed while (in other words, as long as) the condition is true.
Use the until keyword in a loop exit condition to specify that the loop body should be
processed until the condition becomes true, at which time the loop should stop.
Like the condition in an IfThenElse statement, the condition in a Do . . . Loop
statement can contain variables, constants, properties, methods, keywords, and
operators; it also must evaluate to a Boolean value.
In a pre-test loop
The condition is evaluated before the instructions within the loop are processed.
Syntax:
Loop
Example code:
Dim intNumber As Integer = 1
In a post-test loop
The condition is evaluated after the instructions within the loop are processed.
Syntax:
Do
loop body instructions, which will be processed either
while the condition is true or until the condition becomes true
Loop {While | Until} condition
Do
MessageBox.Show(intNumber)
intNumber = intNumber + 1
Loop Until intNumber > 3
Codes:
Timeline:
1992: Microsoft released Access version 1.0 on November 13, 1992, and an Access 1.1 release in
May 1993 to improve compatibility with other Microsoft products and to include the Access Basic
programming language.
1994: Microsoft specified the minimum hardware requirements for Access v2.0 as: Microsoft
Windows v3.1 with 4 MB of RAM required, 6 MB RAM recommended; 8 MB of available hard disk
space required, 14 MB hard disk space recommended. The product shipped on seven 1.44 MB
diskettes. The manual shows a 1994 copyright date.
With Office 95, Microsoft Access 7.0 (a.k.a. "Access 95") became part of the Microsoft Office
Professional Suite, joining Microsoft Excel, Word, and PowerPoint and transitioning from Access
Basic to VBA. Since then, Microsoft has released new versions of Microsoft Access with each
release of Microsoft Office. This includes Access 97 (version 8.0), Access 2000 (version 9.0),
Access 2002 (version 10.0), Access 2003 (version 11.5), Access 2007 (version 12.0), Access 2010
(version 14.0), and Access 2013 (version 15.0).
When you double-click the shortcut, Access opens the database in which the object is
stored and displays the object. If Access is already running and the object associated with the
shortcut is in a database other than the currently open database, a new instance of Access is
started. To open the object in a specific view in Access, right-click the shortcut and then click the
view you want.
NOTE:
If you move the database after you create the shortcut, delete the shortcut and create a
new one.
To delete a shortcut, click it and then press the DELETE key. Deleting the shortcut does
not delete the object that the shortcut opens.
What is database?
A database is an object for storing collection of structured data.
Although a database is a storage location, the main purpose of a database is not much of
a storage but rather focused on quick retrieval and manipulation of information.
To isolate complexities with regards to the internal representation of the database,
database management system (DBMS) programs are commonly used.
Some of DBMS examples include MySQL, Microsoft Access, Oracle and FoxPro.
Their software system are designed to use standard methods in listing, recording, and
generating queries on data to maintain database.
Their capabilities enables programmers to access and store data in an organized manner,
in form of tables.
As shown in the description, Microsoft Access Database file uses .NET Framework
Data Provider for OLE DB.
11. For Database file name, search for UserAccounts.accdb file that was created earlier.
12. To verify connection to your database, click Test Connection.
13. Once the connection was verified, click ok twice to close the Test Connection and Add
Connection dialog box.
14. Click Next on the Data Source Connection Wizard.
15. If a prompt asks you to copy the file to your project, click Yes
16. Save the Connection as UserAccountsConnectionString, then click Next.
17. Add all your objects in the dataset, then click Finish.
18. On your Solution Explorer, open UserAccountsDataSet.xsd in designer mode (Shift +
F7).
Relational Databases:
Relational databases are the main concern for relational model since they are based on
the relationship between the data they contain. Tables contains group of related data or
entries keeping each tables as manageable as possible.
Separate entities are placed on a different table avoiding information to be manually
entered multiple times making it prone to duplication.
One of the main goals in creating a database is to keep information organized and
manageable.
Along with the goal is a simple rule that is followed by database designers: Do not
duplicate information.
Table 1: Books
Table 2: Members
Table 3: Members
3. Create a Windows Form project named LibraryDatabase and connect the LibrarySystem
database into the project.
The number 1 and the infinity symbol on the line defines how objects are related to
each other.