Click here to Skip to main content
15,886,518 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralMenuStrip.GetItemAt returns Nothing Pin
Steven J Jowett7-Apr-08 4:04
Steven J Jowett7-Apr-08 4:04 
GeneralRe: MenuStrip.GetItemAt returns Nothing Pin
Luc Pattyn7-Apr-08 4:51
sitebuilderLuc Pattyn7-Apr-08 4:51 
GeneralRe: MenuStrip.GetItemAt returns Nothing Pin
Aks 0057-Apr-08 5:08
Aks 0057-Apr-08 5:08 
QuestionPeripherals list Pin
signo19767-Apr-08 3:58
signo19767-Apr-08 3:58 
GeneralRe: Peripherals list Pin
Steven J Jowett7-Apr-08 5:09
Steven J Jowett7-Apr-08 5:09 
Questionhow can i change datarow.itemarray member type? Pin
AHeavey7-Apr-08 1:56
AHeavey7-Apr-08 1:56 
GeneralRe: how can i change datarow.itemarray member type? Pin
Dave Kreskowiak7-Apr-08 3:36
mveDave Kreskowiak7-Apr-08 3:36 
GeneralRe: how can i change datarow.itemarray member type? Pin
AHeavey7-Apr-08 3:43
AHeavey7-Apr-08 3:43 
I am reading data from an excel spreadsheet, some fields are text and others are dates. I then read each line into a datarow in a dataset and then pass them to a method to insert them into an access table. Her is my read from excel code:
MyCommand = New System.Data.OleDb.OleDbDataAdapter("select * from [sheet1$]", MyConnection)
MyCommand.Fill(DtSet, "ExcelFields")
MyConnection.Close()
Dim ir As New DBTier
Dim va As New Validate
Dim dr As DataRow
For Each dr In DtSet.Tables("ExcelFields").Rows()
va.ValidateFeilds(dr)
ir.IncidentReportAdd(dr.ItemArray(0).ToString(), dr.ItemArray(1).ToString(), _
dr.ItemArray(5).ToString(), dr.ItemArray(7).ToString(), dr.ItemArray(2).ToString(), _
dr.ItemArray(8).ToString(), dr.ItemArray(10).ToString(), dr.ItemArray(12).ToString(), _
Date.Parse(dr.ItemArray(13).ToString()), Date.Parse(dr.ItemArray(14).ToString()), _
Date.Parse(dr.ItemArray(15).ToString()), Date.Parse(dr.ItemArray(16).ToString()), _
Date.Parse(dr.ItemArray(18).ToString()), Date.Parse(dr.ItemArray(19).ToString()), _
dr.ItemArray(21).ToString())
Next

I need to be able to check if the date is blank and replace it with 1/1/1900 if it is.
GeneralRe: how can i change datarow.itemarray member type? Pin
AHeavey7-Apr-08 3:45
AHeavey7-Apr-08 3:45 
GeneralRe: how can i change datarow.itemarray member type? Pin
Dave Kreskowiak7-Apr-08 6:41
mveDave Kreskowiak7-Apr-08 6:41 
QuestionHow to open cash drawer through Samsung /Star tsp 700 printer in vb6 Pin
harisqued7-Apr-08 1:35
harisqued7-Apr-08 1:35 
AnswerRe: How to open cash drawer through Samsung /Star tsp 700 printer in vb6 Pin
Dave Kreskowiak7-Apr-08 3:32
mveDave Kreskowiak7-Apr-08 3:32 
GeneralSyntax help Pin
blackjack21506-Apr-08 22:23
blackjack21506-Apr-08 22:23 
GeneralRe: Syntax help Pin
Christian Graus6-Apr-08 22:28
protectorChristian Graus6-Apr-08 22:28 
GeneralRe: Syntax help Pin
Steven J Jowett6-Apr-08 22:43
Steven J Jowett6-Apr-08 22:43 
GeneralRe: Syntax help Pin
blackjack21506-Apr-08 22:49
blackjack21506-Apr-08 22:49 
GeneralRe: Syntax help Pin
Luc Pattyn7-Apr-08 0:52
sitebuilderLuc Pattyn7-Apr-08 0:52 
GeneralRe: Syntax help Pin
Chinners6-Apr-08 22:50
Chinners6-Apr-08 22:50 
Question(missing code} detect path service Pin
hassanasp6-Apr-08 11:57
hassanasp6-Apr-08 11:57 
GeneralRe: (missing code} detect path service Pin
Christian Graus6-Apr-08 15:44
protectorChristian Graus6-Apr-08 15:44 
GeneralRe: (missing code} detect path service Pin
Luc Pattyn7-Apr-08 0:56
sitebuilderLuc Pattyn7-Apr-08 0:56 
GeneralRe: (missing code} detect path service Pin
Christian Graus7-Apr-08 1:01
protectorChristian Graus7-Apr-08 1:01 
Questionhow to check correct answer in quiz Pin
bapu28896-Apr-08 9:01
bapu28896-Apr-08 9:01 
GeneralRe: how to check correct answer in quiz Pin
Christian Graus6-Apr-08 11:13
protectorChristian Graus6-Apr-08 11:13 
QuestionRe: how to check correct answer in quiz Pin
bapu28897-Apr-08 8:19
bapu28897-Apr-08 8:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.