2013-01-27

Microsoft Visual Studio Pro 2012


Product Features


  • Deep interoperability with business and consumer platforms lets you build what your users want, where they want it
  • Create apps in a streamlined UI where common tasks are presented in a fresh, integrated development experience
  • Consolidate many development tasks into one tool so you can enhance existing apps or build new modern ones
  • Requirements: Processor - 1.6GHz+ CPUOS - Windows 8 (x86/x64), Windows 7 SP1 (x86/x64), Windows Server 2008 R2 SP1 (x64), Windows Server 2012 (x64)Memory(RAM) - 1GB (1.5GB if running on a virtual machine.


Why buy Visual Studio Professional with MSDN?
Software development doesn’t stand still—you push the technology envelope one day, and then need yesterday’s platforms and tools to support legacy apps the next. Visual Studio Professional with MSDN gives you access to Microsoft platforms and tools from the past and present, with new releases being added all the time. Plus, since it includes Team Foundation Server, you get the tools you need to work well with others. And now you have services to take your apps to the cloud, Windows Store, and Windows Phone Marketplace. Get Visual Studio Professional with MSDN and raise your development game.


2011-12-12

Read excel to dataset

This sample show how to read data from excel file by using Microsoft.Jet.OLEDB.

More information about excel connectionstring see http://www.connectionstrings.com/excel

Let's sample code.

Private Function ReadExcelFile(ByVal filePath As String, ByVal fileName As String) As DataSet
'' Excel 2003
Dim sConn As String = String.Format("Provider=Microsoft.Jet.OLEDB.4.0;Data Source={0}", filePath + fileName)
sConn += ";Extended Properties=""Excel 8.0;HDR=Yes;IMEX=1;"""

'Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\MyExcel.xls;Extended Properties="Excel 8.0;HDR=Yes;IMEX=1";

Dim sSql As String = "SELECT * FROM [Sheet1$]"
'Select excel range command
' Dim sSql As String = "SELECT * FROM [Sheet1$A1:D3]"

Dim pFile As New FileInfo(fileName)
If (pFile.Extension.ToLower() = ".xlsx") Then
' Excel 2007
sConn = String.Format("Provider=Microsoft.ACE.OLEDB.12.0;Data Source={0}", filePath + fileName)
sConn += ";Extended Properties=""Excel 12.0 Xml;HDR=YES;"""
End If


Dim ds As New DataSet
Dim pConn As New OleDbConnection(sConn)
Try
pConn.Open()
Dim pCmd As New OleDbCommand()
pCmd.Connection = pConn
pCmd.CommandText = sSql

Dim pAdp As New OleDbDataAdapter()
pAdp.SelectCommand = pCmd

pAdp.Fill(ds)
Catch ex As Exception
Return Nothing
Finally
pConn.Close()
End Try

Return ds
End Function

Note
If found error Could not find installable ISAM that mean your connectionstring was wrong.


2011-06-21

ListView

1. Design ListView like this picture.



2. Set Listview property

FullRowSelect = True
GridLines = True
UseCompatibleStateImageBehavior = False
View = Details

3. Using System.Windows.Forms.ListView

4. Sample code to add item to listview (When click button add item to listview)
Dim pObj As New ListViewItem("Code")
pObj.SubItems.Add("Item Name")
pObj.SubItems.Add("10.00")
pObj.SubItems.Add("1")
pObj.SubItems.Add("1.50"))
pObj.SubItems.Add("15.00")
pObj.Tag = 1 ' keep materail id ListView1.Items.Add(pObj)

5. Sample code to delete item in listview when press delete on keyboard.
Private Sub ListView1_KeyUp(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles lstMaterial.KeyUp
If e.KeyCode = Keys.Delete AndAlso ListView1.SelectedItems.Count > 0 Then
For i As Integer = ListView1.SelectedItems.Count - 1 To 0 Step -1
ListView1.Items.RemoveAt(ListView1.SelectedItems(i).Index)
Next
End If
End Sub

2010-02-23

Send Email By SMTP

Imports System.Net.Mail


Public
Sub SendEmail()

Dim client As New SmtpClient()
Dim sendTo As New MailAddress("sendToAccount@gmail.com")
Dim from As MailAddress = New MailAddress("from@address.com")
Dim
message As New MailMessage(from,sendTo)


message.IsBodyHtml = True
message.Subject = "Test SMTP"
message.Body = "Got it!!"

' Use the same account in app.config to authenticate.
Dim basicAuthenticationInfo As New System.Net.NetworkCredential("yourAccount@xxx.com", "YourPassword")


client.Host = "smtp.xxx.com"
client.UseDefaultCredentials = False

client.Credentials = basicAuthenticationInfo

'' For smtp config
'' google use EnableSsl=True and Port = 587

client.EnableSsl = False
client.Port = 25

Try

client.Send(message)
Console.WriteLine("SUCCESS")

Catch ex As Exception

Console.WriteLine("SEND FAIL")

End Try

End Sub

2010-02-22

Developer Books

Developer Books



Professional Visual Basic 2008 (Programmer to Programmer)

* Paperback: 1420 pages
* Publisher: Wrox (May 5, 2008)
* Language: English
* ISBN-10: 0470191368
* ISBN-13: 978-0470191361

Product Description
Professional Visual Basic 2008

The 2008 version of Visual Basic is tremendously enhanced and introduces dramatic new concepts, techniques, and features to this popular object-oriented language. Written by an elite author team who are sympathetic to the challenges of learning VB 2008, this comprehensive book provides a clear and concise approach to using VB 2008 in the ever-expanding .NET world.

This book focuses on using the latest and most powerful tools from the Microsoft arsenal within your Visual Basic solutions. Looking closely at LINQ, AJAX, a new Visual Studio and more, you'll be able to take lessons from this book and apply them to what you are doing today. You'll examine everything from the .NET Framework to the best practices for deploying .NET applications to database access and integrating with other technologies, such as COM and XML.

What you will learn from this book

* The core elements of VB 2008 as well as full syntax of all the new additions the language offers
* Ways that the Common Language Runtime (CLR) is responsible for managing the execution of code compiled on the .NET platform
* How VB is used in the creation, installation, running, and debugging of Windows? Services
* How to work with the new SQL Server 2008 along with your .NET applications
* The many features of Windows Forms and Windows Presentation Foundation
* Ways to take advantage of the abilities of LINQ
* The new web technology introduced by Silverlight

Who this book is for

This book is for experienced developers who are looking to transition to the latest version of Visual Basic.

Wrox Professional guides are planned and written by working programmers to meet the real-world needs of programmers, developers, and IT professionals. Focused and relevant, they address the issues technology professionals face every day. They provide examples, practical solutions, and expert education in new technologies, all designed to help programmers do a better job.





Microsoft Visual Basic .NET Programmer's Cookbook (Pro-Developer)

Finally, a book with one-stop shopping for VB.NET! I’ve read several cookbook-style programming titles in the past, and I was pleasantly surprised to find this has much more depth than I expected. It can’t cover everything (.NET is huge), but every time I pick the book up I learn something new. There are so many highlights–just browse through the table of contents and you’ll see what I mean!
Here are some of my favorites:
* Send keystrokes to another app
* Create a thread-safe control wrapper
* Great data-binding tips (image-to-picture box, etc.)
* Factory, Registry, Singleton, Memento, and Lazy Initialization patterns
* POP3, FTP, and Ping classes in the networking section
* How to change a password into a salted hash for storage in a database
* Use ZIP and PDF files (disclaimer: some third-party code is required, although it’s free)
* Manage print jobs that are underway
* Get Windows accounts and roles
* Do hit testing with custom graphics
* Defend against SQL injection
* Dynamically generate an ASP.NET graphic
* Add ASP.NET controls on the fly
* MAPI and MCI (unfortunately, just through the ActiveX controls)
* Upload binary data with a web service
* Use a web service in VB 6

Written by cellphonereview on Dec-21-09 9:08pm
From: bestdp.com






Inside Microsoft SQL Server 2008: T-SQL Programming (Pro-Develper)

Product Description
Tackle the toughest set-based querying and query tuning problems—guided by an author team with in-depth, inside knowledge of T-SQL. Deepen your understanding of architecture and internals—and gain practical approaches and advanced techniques to optimize your code’s performance. Discover how to:
* Move from procedural programming to the language of sets and logic
* Optimize query tuning with a top-down methodology
* Assess algorithmic complexity to predict performance
* Compare data-aggregation techniques, including new grouping sets
* Manage data modification—insert, delete, update, merge—for performance
* Write more efficient queries against partitioned tables
* Work with graphs, trees, hierarchies, and recursive queries
* Plus—Use pure-logic puzzles to sharpen your problem-solving skills