wezel Freshman
Joined: 09 Oct 2003 Posts: 30
|
Posted: Feb 18th, 2004 06:25 AM Post subject: A |
|
|
Hey folks,
I was wondering how I can put text in a cell. I haven't got much VBA expirience. Here's the code I use:
Sub AddNota()
Dim strinputDate As String, strInputNota As String
Dim intLoop As Integer
intLoop = 4
strinputDate = InputBox("Op welke datum wilt u een nota zetten ?", "Nota Bijvoegen")
If strinputDate = "vbCancel" Or strinputDate = "" Then
Exit Sub
End If
strInputNota = InputBox("Welke nota wilt u bijvoegen ?", "Nota Bijvoegen")
If strInputNota = "vbCancel" Or strInputNota = "" Then
Exit Sub
End If
Do While Sheet2.Range("B" & intLoop).Text <> ""
intLoop = intLoop + 1
Loop
Sheet2.Range("B" & intLoop).Text = strinputDate
Sheet2.Range("C" & intLoop).Text = strInputNota
End Sub
This doesn't work.. any Idea how it should work ? _________________ Real Programmers don't comment their code - it's hard to write, it should be hard to read |
|