Click here to Skip to main content
16,011,120 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: reference,instance,object? Pin
Vimalsoft(Pty) Ltd4-Mar-08 22:57
professionalVimalsoft(Pty) Ltd4-Mar-08 22:57 
Generalprogress bar Pin
Tauseef A4-Mar-08 19:43
Tauseef A4-Mar-08 19:43 
GeneralRe: progress bar Pin
parth.p4-Mar-08 22:10
parth.p4-Mar-08 22:10 
GeneralRe: progress bar Pin
Dave Kreskowiak5-Mar-08 1:32
mveDave Kreskowiak5-Mar-08 1:32 
GeneralDateTime Picker selecting month and year only Pin
AAGTHosting4-Mar-08 18:38
AAGTHosting4-Mar-08 18:38 
GeneralRe: DateTime Picker selecting month and year only Pin
Christian Graus4-Mar-08 18:58
protectorChristian Graus4-Mar-08 18:58 
GeneralRe: DateTime Picker selecting month and year only Pin
ChandraRam4-Mar-08 22:32
ChandraRam4-Mar-08 22:32 
Generalsubscript out of range Pin
Danisto4-Mar-08 18:32
Danisto4-Mar-08 18:32 
hi, please see code below...i keep on get in a "subscript out of range" error for the array v(n), my option base is 0

even if i reset the array to v(n-1) it does not accept. is the something i am missing

Public Function datevec(d1 As Variant, d2 As Variant, freq As Variant)
Dim v()
Dim n As Long
Dim c1, c2 As Date
ReDim v(n) As Variant
If IsDate(d1) = True And IsDate(d2) = True Then
c1 = DateSerial(Year(d1), Month(d1), Day(d1))
c2 = DateSerial(Year(d2), Month(d2), Day(d2))

n = Application.Round(VBA.DateDiff("d", c1, c2) / 365 * freq, 0)

Select Case freq
Case 1
For Each i In v(n)
v(i) = VBA.DateAdd("yyyy", i + 1, c1)
Next i
Case 2
For Each i In v(n)
v(i) = VBA.DateAdd("q", 2 * (i + 1), c1)
Next i
Case 4
For Each i In v(n)
v(i) = VBA.DateAdd("q", i + 1, c1)
Next i
Case 12
For Each i In v(n)
v(i) = VBA.DateAdd("M", i + 1, c1)
Next i
End Select

datevec = v
End If
End Function
GeneralRe: subscript out of range Pin
soporificeffect4-Mar-08 20:23
soporificeffect4-Mar-08 20:23 
QuestionCreate a dbase Trigger in Access Pin
IvanIT4-Mar-08 17:47
IvanIT4-Mar-08 17:47 
GeneralRe: Create a dbase Trigger in Access Pin
Dave Kreskowiak5-Mar-08 1:28
mveDave Kreskowiak5-Mar-08 1:28 
GeneralRe: Create a dbase Trigger in Access Pin
IvanIT5-Mar-08 3:19
IvanIT5-Mar-08 3:19 
GeneralProblem while report genration in VB Pin
yogesh_kumar_agarwal4-Mar-08 16:43
yogesh_kumar_agarwal4-Mar-08 16:43 
GeneralRe: Problem while report genration in VB Pin
ChandraRam4-Mar-08 22:14
ChandraRam4-Mar-08 22:14 
GeneralRe: Problem while report genration in VB Pin
yogesh_kumar_agarwal4-Mar-08 22:26
yogesh_kumar_agarwal4-Mar-08 22:26 
GeneralRe: Problem while report genration in VB Pin
ChandraRam4-Mar-08 22:30
ChandraRam4-Mar-08 22:30 
GeneralRe: Problem while report genration in VB Pin
yogesh_kumar_agarwal4-Mar-08 22:35
yogesh_kumar_agarwal4-Mar-08 22:35 
GeneralRe: Problem while report genration in VB Pin
ChandraRam4-Mar-08 22:39
ChandraRam4-Mar-08 22:39 
GeneralRe: Problem while report genration in VB Pin
yogesh_kumar_agarwal4-Mar-08 22:45
yogesh_kumar_agarwal4-Mar-08 22:45 
GeneralRe: Problem while report genration in VB Pin
yogesh_kumar_agarwal4-Mar-08 22:53
yogesh_kumar_agarwal4-Mar-08 22:53 
GeneralRe: Problem while report genration in VB Pin
ChandraRam4-Mar-08 22:55
ChandraRam4-Mar-08 22:55 
GeneraltextBox content in different forms Pin
Awoujol4-Mar-08 11:57
Awoujol4-Mar-08 11:57 
GeneralRe: textBox content in different forms Pin
Christian Graus4-Mar-08 12:58
protectorChristian Graus4-Mar-08 12:58 
AnswerRe: textBox content in different forms Pin
Tauseef A4-Mar-08 19:56
Tauseef A4-Mar-08 19:56 
GeneralDataGridView - how to appear to have two columns with one column heading Pin
Kschuler4-Mar-08 5:52
Kschuler4-Mar-08 5:52 

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.