|
code
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
New to Vb, listbox & DataGrid helpI'm new to VB 2008, I'm trying to load data into two colunms of a list box or datagrid. I'm not sure how to get my data into the second colunms of the list box and If I can post this type of data into a data grid view. any suggestions are welome. also, can headers be added to a list box? Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim elevDsection As Double elevDsection = 150 Dim strFormat As String strFormat = "#0.00" Dim slope As Double Dim samplestartdist As Double Dim sampledist As Double Dim rwoffset As Double Dim offsetelevdist As Double Dim offsetelev As Double slope = 1 / 34 offsetelevdist = 100 offsetelev = (slope * offsetelevdist) + elevDsection samplestartdist = 0 sampledist = 500 + offsetelevdist rwoffset = 0 rwoffset = rwoffset Me.ListBox1.FormattingEnabled = True Me.ListBox1.HorizontalScrollbar = False Do While sampledist > 0 ListBox1.Items.Add(rwoffset) rwoffset = rwoffset + offsetelevdist sampledist = sampledist - offsetelevdist offsetelev = (slope * rwoffset) + elevDsection Loop end sub "jcoon" <jcoo***@comcast.net> wrote in message You're in the wrong newsgroup. This is a Visual Basic group and VB 2008 is news:ODwa0DAoJHA.5420@TK2MSFTNGP04.phx.gbl... > All, I'm new to VB 2008, I'm trying to load data . . . not Visual Basic, despite its deliberately misleading marketing name. Visual Basic code will not work in VB 2008, and VB 2008 code will not work in Visual Basic. Try posting your question to a VB.Net group, such as: microsoft.public.fotnet.languages.vb Mike
Wrap a Long String
Determining Available Paper Sizes on Printer Number Puzzle vb6 closes with erro after I installed msdn oct 2001 Subclassing a la Caton Error #429 and compactdatabase in VB6 ListBox bug? Excel Library in VB 2008 on 64-bit OS installation Using VBPRNDLG.DLLl Instead of Print Common Dialog Boxes VSM Wants Your Feedback |
|||||||||||||||||||||||