|
-
Aug 31st, 2000, 08:59 PM
#1
Thread Starter
New Member
Currently,my prog. has a listbox which displays all the records from db,however right now i need to implement it such that a check box is allocated along with each of the data.How do i do that? Can i use data repeater ?? any ideas ... thanks
Cheers
Cariz
-
Aug 31st, 2000, 09:07 PM
#2
_______
<?>
Componets/Windows common Controls 6 I think
A ListView is one type of control you could use.
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Aug 31st, 2000, 09:39 PM
#3
Fanatic Member
Paul Dwyer 
Network Engineer
Aussie In Tokyo
Using Powerbasic 6 & VB6 SP4 (Please also add your VB Version to your signature!)
-
Aug 31st, 2000, 09:42 PM
#4
_______
<?>
I could have sworn they had that capicity but I couldn't find the darn thing. [B}Style[/b] and I'm combing the mine fields looking for Check....da da dum dum
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Aug 31st, 2000, 10:47 PM
#5
Thread Starter
New Member
hey Joe,thanks for the info. but i'm kinda new to listview...do you happened to know any tutorials on this?would appreciate it.tHanks..
Cheers
Cariz
-
Aug 31st, 2000, 10:51 PM
#6
_______
<?>
In case you missed it Paul has noted that the listbox itself has the checkbox capabilites under style. I'll see if I have anything on listview.I know I can't have much I've only use the control on a few occassions.
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Aug 31st, 2000, 11:05 PM
#7
_______
<?>
Code:
I found this..it might be right along the lines you are
looking for. If you can't find anything on listviews here
then just go to my web page / links and there are 5 or 6 very good VB sites listed...Code Archive comes to mind as
having very good zip files on controls.
Wayne
Option Explicit
' Populate a listview with checkboxes
' using a field from a database as caption
Private Sub Form_Load()
ListView1.Checkboxes = True
Dim l As Long
Dim dblRnd As Double
Dim dteRnd As Date
With ListView1
'this is your header
.ColumnHeaders.Add(, , "String").Tag = "File Listing"
' Set the column alignment
.ColumnHeaders(1).Alignment = lvwColumnLeft
End With
'
' Set BorderStyle property.
ListView1.BorderStyle = ccFixedSingle
'
' Set View property to Report.
ListView1.View = lvwReport
'
Dim Index As Long
Dim sql
sql = "select * from tips"
Data1.RecordSource = sql
Data1.Refresh
' Populate the list with data
While Not Data1.Recordset.EOF
With ListView1.ListItems.Add(, , Index & " " & Data1.Recordset!sListing)
Index = Index + 1
End With
Data1.Recordset.movenext
Wend
End Sub
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Aug 31st, 2000, 11:15 PM
#8
Thread Starter
New Member
hee
thanks to you both anyways...maybe i'd log off and try on your codes.
-
Sep 1st, 2000, 02:58 AM
#9
Thread Starter
New Member
Hey guys i was just thinking of using dataRepeater to display info from db but i wanna know if info can be updated to the db.Another qn is,if i were to use listview...it is possible to add multiple checkboxes to specified columns that are under the same list item.How do i do that..?i looked thro the internet for its functions but they seem to not facilate that feature.
tHAnks ~
Cariz
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|