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

Visual Basic

 
AnswerRe: How do I show an uncommon image format? Pin
Dave Kreskowiak4-Oct-08 5:25
mveDave Kreskowiak4-Oct-08 5:25 
GeneralRe: How do I show an uncommon image format? Pin
Sonhospa4-Oct-08 8:42
Sonhospa4-Oct-08 8:42 
GeneralRe: How do I show an uncommon image format? Pin
Dave Kreskowiak4-Oct-08 13:18
mveDave Kreskowiak4-Oct-08 13:18 
QuestionVB.NET comboBox help !! Pin
Saam_cse4-Oct-08 0:55
Saam_cse4-Oct-08 0:55 
AnswerRe: VB.NET comboBox help !! Pin
Dave Kreskowiak4-Oct-08 5:19
mveDave Kreskowiak4-Oct-08 5:19 
AnswerRe: VB.NET comboBox help !! Pin
Vimalsoft(Pty) Ltd5-Oct-08 0:19
professionalVimalsoft(Pty) Ltd5-Oct-08 0:19 
AnswerRe: VB.NET comboBox help !! Pin
jzonthemtn5-Oct-08 7:43
jzonthemtn5-Oct-08 7:43 
QuestionVB.NET INTERESTING PROBLEM-- MOVING AVERAGE ,, NEED HELP !!!! Pin
adarshyam3-Oct-08 18:45
adarshyam3-Oct-08 18:45 
Hi friends,
I have an interesting problem in vb.net. And I am struggling to get a solution for this..m trying for the past 3days.. It’s to calculate moving average for the inputs given by the user..

The following are the steps..
1, get 2user inputs in textbox(1st input is number is periods, 2nd is moving range)
2, after getting both the user inputs, the user will click on an input button which must dynamically generate rows for the number of periods given by the user as well as a calculate button must appear dynamically.
3, the user again inputs the values for all the dynamically generated rows and when by pressing calculate button, the moving average for the given moving range must appear in another column

Im half way through and I have attached my progress here.. I would greatly appreciate if u complete it for me.. thanks in advance


Partial Public Class _Default
Inherits System.Web.UI.Page




Protected Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

Dim TxtDyn1 As TextBox()
Dim TxtDyn2 As TextBox()
Dim TxtDyn3 As TextBox()
Dim TxtDyn4 As TextBox()
Dim numofper As Integer

Try

'to check the textbox for empty

If Not TextBox1.Text Is String.Empty Then
numofper = TextBox1.Text
ReDim TxtDyn1(numofper)
ReDim TxtDyn2(numofper)
ReDim TxtDyn3(numofper)
ReDim TxtDyn4(numofper)

Else
Exit Sub
End If

'To create the dynamic text box and add the controls to panel
For i As Integer = 0 To numofper - 1
TxtDyn1(i) = New TextBox
Panel1.Controls.Add(TxtDyn1(i))
Next
For j As Integer = 0 To numofper - 1
TxtDyn2(j) = New TextBox
Panel2.Controls.Add(TxtDyn2(j))
Next
For k As Integer = 0 To numofper - 1
TxtDyn3(k) = New TextBox
Panel3.Controls.Add(TxtDyn3(k))
Next
For l As Integer = 0 To numofper - 1
TxtDyn4(l) = New TextBox
Panel4.Controls.Add(TxtDyn4(l))
Next

Dim mybutton As New Button (THIS S NOT WORKING )
mybutton.Text = "button 2"
AddHandler mybutton.Click, AddressOf button2.click
Me.Controls.Add(mybutton)

Catch ex As Exception
MsgBox("Enter a valid Number")
End Try

End Sub


End Class
AnswerRe: VB.NET INTERESTING PROBLEM-- MOVING AVERAGE ,, NEED HELP !!!! Pin
Dave Kreskowiak4-Oct-08 5:17
mveDave Kreskowiak4-Oct-08 5:17 
GeneralRe: VB.NET INTERESTING PROBLEM-- MOVING AVERAGE ,, NEED HELP !!!! Pin
adarshyam6-Oct-08 7:22
adarshyam6-Oct-08 7:22 
QuestionHow to disable / hide Start Orb in Windows Vista using Visual Basic 6 (not VB.Net, VB2005 or VB2008 or C# or C++ !!!) Pin
Vladimir Nazarov3-Oct-08 15:18
Vladimir Nazarov3-Oct-08 15:18 
AnswerRe: How to disable / hide Start Orb in Windows Vista using Visual Basic 6 (not VB.Net, VB2005 or VB2008 or C# or C++ !!!) Pin
jzonthemtn3-Oct-08 15:43
jzonthemtn3-Oct-08 15:43 
QuestionFunction Delegate Pin
nlarson113-Oct-08 11:21
nlarson113-Oct-08 11:21 
AnswerRe: Function Delegate Pin
Dave Kreskowiak3-Oct-08 12:26
mveDave Kreskowiak3-Oct-08 12:26 
GeneralRe: Function Delegate Pin
nlarson113-Oct-08 13:46
nlarson113-Oct-08 13:46 
GeneralRe: Function Delegate Pin
Guffa4-Oct-08 1:06
Guffa4-Oct-08 1:06 
AnswerRe: Function Delegate Pin
John_Adams3-Oct-08 12:27
John_Adams3-Oct-08 12:27 
GeneralRe: Function Delegate Pin
nlarson113-Oct-08 13:51
nlarson113-Oct-08 13:51 
AnswerRe: Function Delegate Pin
Gideon Engelberth3-Oct-08 15:55
Gideon Engelberth3-Oct-08 15:55 
QuestionCustom control Pin
Tom Deketelaere3-Oct-08 9:17
professionalTom Deketelaere3-Oct-08 9:17 
AnswerRe: Custom control Pin
nlarson113-Oct-08 10:27
nlarson113-Oct-08 10:27 
GeneralRe: Custom control Pin
Tom Deketelaere3-Oct-08 11:29
professionalTom Deketelaere3-Oct-08 11:29 
GeneralRe: Custom control Pin
Dave Kreskowiak3-Oct-08 12:19
mveDave Kreskowiak3-Oct-08 12:19 
GeneralRe: Custom control Pin
Tom Deketelaere4-Oct-08 0:50
professionalTom Deketelaere4-Oct-08 0:50 
QuestionVB COM object works fine when called from server, but not workstation... Pin
rahvyn133-Oct-08 6:39
rahvyn133-Oct-08 6:39 

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.