1 / 38

VISUAL BASIC 2005 EXPRESS

VISUAL BASIC 2005 EXPRESS. - Lakoća programiranja - Dragan Janković Katedra za Računarstvo Elektronski fakultet, Niš. Sve to može ovako. A može i ovako. Express Pro izvodi. Učenje .NET. Učenje VB. Kreiranje apli kacija. Penzioneri. Hobi. U čenici. Studenti. RAD ?. Brzo u č enje

katoka
Download Presentation

VISUAL BASIC 2005 EXPRESS

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. VISUAL BASIC 2005 EXPRESS - Lakoća programiranja - Dragan Janković Katedra za Računarstvo Elektronski fakultet, Niš

  2. Sve to može ovako

  3. A može i ovako Express Proizvodi

  4. Učenje.NET Učenje VB Kreiranjeaplikacija Penzioneri Hobi Učenici Studenti

  5. RAD ? • Brzo učenje • Motivacija • Brz i efikasan razvoj aplikacija • Gotovi elementi interfejsa • Programiranje upravljano dogadjajima • “Programiranje mišem” • Drag & Drop • Podesi • Dopuni

  6. VB2005 .NET Visual Basic VB .NET Jednostavnije i efikasnije Basic

  7. Visual Basic .NET • Unapredjen jezik • Potpuno podržana OO paradigma: • Klase, nasleđivanje, konstruktori, destruktori • Overloading, polimorfizam, ... • Obrada izuzetaka • Potpuni pristup .NET frameworku • Multithread, garbage collection • Unapredjen razvoj Web apikacija • Kreiranje Web formi po ugledu na Windows forme • Kreiranje Web servisa – jednostavno • Poboljšan security • Jednostavan i fleksibilan deployment

  8. Šta je novo? • IntelliSense Filtering • IntelliSense in Zone • New VB Item Templates • Find References • Exportable Development Settings • Simplified Tools -> Options • Project Designer • Starter Kits • XML Editor • Zero Impact Projects • Start Page • Authenticode signing support • Custom Setup Bootstrapper • Big 5 Bootstrapper packages(Fx 2.0, SSE, etc.) • Strongly typed Resources • Edit and Continue • My • Generics • Click Once • Data Sources Windows • Object Binding • Web Service Binding • Debugger Visualizers • Just My Code Debugging • The Exception Assistant • Design Time Expression Evaluation • IntelliSense Code Snippets • XML Comments • Error Correction and Warnings • Rename • Attribute Editing

  9. Lookup table binding • Upgrade WebBrowser • Upgrade Masked Edit • Upgrade Rich textbox • Upgrade Windows Common Controls • TreeView, ListView, ImageList • ToolBar, StatusBar, ProgressBar • Upgrade Common Dialogs • Upgrade MTS/COM+ Projects • Upgrade BackgroundImageLayout Property • Upgrade keys in KeyPress event • Upgrade additional Keywords • Updated Keys In Control Collections • Upgrade Unload Mode in FormClosing Event • Registration Free COM • Strongly typed Settings • Using statement • Continue statement • Global keyword • Accessor accessibility • Partial types • Unsigned types • Operator overloading • Warnings • Custom Events • TableAdapters • DataSet Designer • Drag Once Form creation • Smart Tags • Parameterized query • Connect the Dots databinding • Custom Control drag / drop

  10. Nešto više o ... • Generics • Partial Types • IsNot • Continue • Operator overloading • My Object (namespace) • Code Snippets • …

  11. Generics Private _Items As Collection Private Sub Class_Initialize() Set _Items = New Collection End Sub Private Sub Class_Terminate() Set _Items = Nothing End Sub Public Function NewEnum() As stdole.IUnknown Set NewEnum = moItems.[_NewEnum] End Function Public Function Item(Key As String) As Person On Error Resume Next Set Item = _Items.Item(Key) End Function Public Property Get Count() As Long Count = _Items.Count End Property Public Sub Add(Person As Person, Key As String) _Items.Add Text, Text.Key End Sub Public Sub Remove(Index As Integer) _Items.Remove Index End Sub VB6 Public Class Cars : Inherits CollectionBase Public Sub Add(ByVal item As Person) MyBase.InnerList.Add(item) End Sub Default Property Item(ByVal index As Integer) As Person Get Return DirectCast(MyBase.InnerList(index), Person) End Get Set(ByVal Value As Person) MyBase.InnerList(index) = Value End Set End Property End Class VB.NET VB2005 Dim Cars As New List(Of Car) Cars.Add(New Car())

  12. Zašto Generics? • Kod tipiziran • Izbegnute run-time greške • IntelliSense radi • Bolje performanse • Primer: Efikasnost realizacije primenom • Array 344 • ArrayList 4656 • Generic List 797

  13. Partial Types File Class1.vb Public Class Car Public Sub Start() End Sub End Class Dim T As New Car() T.Start() T.Stop() File Class2.vb Public Partial Class Car Public Sub Stop() End Sub End Class

  14. IsNot Operator Public Sub Test(ByVal o As SomeType) If Not o Is Nothing Then o.DoSomething() Else Throw New NullReferenceException() End If End Sub Public Sub Test(ByVal o As SomeType) If o IsNot Nothing Then o.DoSomething() Else Throw New NullReferenceException() End If End Sub

  15. Continue Dim i, j, k As Int32Dim rnd As New Random(DateTime.Now.Millisecond)For i = 0 To 5 j = 0While (j < 3)   j += 1   k = 0Do    k += 1    If (rnd.Next(100) >= 90) Then Continue ForLoop Until k > jEnd While Debug.WriteLine(String.Format("{0} {1} {2}", i, j, k))Next For i as Int32=0 to 10 If (i mod 2 =0 ) Then Continue For Debug.WriteLine(i) ‘ 1,3,5,7,9 Next

  16. Overloading operatora Public Class SetPoint Public Temperature as Single Public Sub New (value as Single) Me.Temperature=value End Sub Public Shared Operator +(ByVal a As SetPoint,_ ByVal b As SetPoint) As SetPoint Return New SetPoint(a.Temperature + b.Temperature) End Operator End Class Public Class SetPoint Public Temperature as Single Public Sub New (value as Single) Me.Temperature=value End SubEnd Class Dim T1 as New SetPoint(12.5)Dim T2 as New SetPoint(13)Dim T3 as SetPoint = T1 + T2

  17. Overloading operatora(2) • Public Class Complex • Public Real As Double • Public Imag As Double • Public Sub New(ByVal rp As Double, ByVal ip As Double) • Real = rp • Imag = ip • End Sub • Shared Operator +(ByVal lhs As Complex, ByVal rhs As Complex)_ • As Complex • Return New Complex(lhs.Real + rhs.Real, lhs.Imag + rhs.Imag) • End Operator • End Class • 'new Complex + operator works intuitively • Dim lhs As Complex = New Complex(2.1, 3.3) • Dim rhs As Complex = New Complex(2.5, 4.6) • Dim res As Complex = lhs + rhs • 'res.real = 4.6, res.imag = 7.9

  18. My Namespace — Application title, version, logs, description, … — Registry, Printer, Audio, File System, … — User name, group, domain, … —Pristup resursi aplikacije: icons, images, … — User i application settings —Kolekcija formi u aplikaciji, show / hide — Jednostavan pristup web servisima ukjučenim u projekat (Web references)

  19. My.Resources • PictureBox1.Image = My.Resources.Logo • My.Settings • My.Settings.FormLocation = Me.Location • My.Forms • My.Forms.Form1.Show • My.WebServices • My.WebServices.MSDN.Search(“VB”)

  20. Code Snippets Desni-klik u editoru koda i selekcija taska izaziva insetovanje ranije pripremljenog koda.

  21. Start Page uVB 2005 Express

  22. Prikaz Web strane

  23. New Project dijalog

  24. Design mode

  25. Meni

  26. Meni (nastavak)

  27. Toolbar

  28. Help • Dinamički help • Context-Sensitive Help

  29. Komande Help menija

  30. Dinamički help

  31. Context sensitive help

  32. Kako učiti? • 2373B Programming with Microsoft Visual Basic .NET • Microsoft IT Academy – Elektronski fakultet u Nišu • PIL program:Microsoft Software & ELEF • Portal: www.pil-vb.net • Dušan Vučković, Elektronski fakultet, Niš • dvuckovic@elfak.ni.ac.yu • gaga@elfak.ni.ac.yu

  33. VB.NET 2005

More Related