- Messages
- 121
- Reaction score
- 0
- Points
- 26
Guys pa help naman ako sa problem ko.. Gumagawa ako now ng system sa vb6. ang problem ko po eh. ung sa listview. Ganito po yung scenario, gumawa ako ng mga textbox, command button at listview na pag niclick ko yung command button, yung laman ng textbox eh ma-aadd sa listview. Ang problema ko, pag niclick ko na yung command button, lumalabas yung error na "Run-time Error 13: Type mismatch. Nung ginagawa ko po sya sa isang blank na project, working sya. Kaya lang pag nilagay ko na sya sa system na ginagawa ko, nakukuha ko naman yung error na nabanggit ko. Ito nga po pala yung code ko...
Please help po... Badly need ko po talaga ang help.
Dim AddTransaction As ListItem
If Len(cbo_itemcode.Text) = 0 Or Len(cbo_itemname.Text) = 0 Or Len(txt_itemqty.Text) = 0 Then
MsgBox "Please fill all fields", vbOKCancel + vbCritical, "Error"
Else
Set AddTransaction = lst_transaction.ListItems.Add(1, , txt_itemnum.Text, , 0)
'AddTransaction.Text = txt_itemnum.Text
AddTransaction.SubItems(1) = cbo_itemcode.Text
AddTransaction.SubItems(2) = cbo_itemname.Text
AddTransaction.SubItems(3) = txt_itemtype.Text
AddTransaction.SubItems(4) = txt_itemdesc.Text
AddTransaction.SubItems(5) = txt_supname.Text
AddTransaction.SubItems(6) = txt_supcode.Text
AddTransaction.SubItems(7) = txt_supprice.Text
AddTransaction.SubItems(8) = txt_itemsrp.Text
AddTransaction.SubItems(9) = txt_itemqty.Text
Set AddTransaction = Nothing
End If
Please help po... Badly need ko po talaga ang help.