Hi All !
I'm a beginner in VB2008 (Express Ed). I'm building an application to manage an Role Playing Game Character Sheet (like AD&D for the ones who know what it is)
I'm trying to create the Inventory of my Character and for this purpose I would like to create a custom control ...let's say Inventory_Item with many Properties (ex: Value, Category, is Magical etc..etc..) Then use many instances of this object to poplate a listview.
Right now i've build up the class Inventory_Item (see following code)
Public
Private isMagical As Boolean = False
Private isValuable As Boolean = False
Private _Category As String = ""
Private _Qty As Integer = 0
Private _Value As Integer = 0
Private _Name As String = ""
Private _Index As Integer = 0
Public Property Index() As Integer
Get
Return _Index
End Get
Set(ByVal value As Integer)
_Index = value
End Set
End Property
Public Property Name() As String
Return _Name
Set(ByVal value As String)
_Name = value
Public Property Magical() As Boolean
Return isMagical
Set(ByVal value As Boolean)
isMagical = value
Public Property Valuable() As Boolean
Return isValuable
isValuable = value
Public Property Value() As Integer
Return _Value
_Value = value
Public Property Category() As String
Return _Category
_Category = value
Public Property Qty() As Integer
Return _Qty
_Qty = value
My problem is that I don't know how to create a "matrix" or array of this control, modify some properties of some of them and use the listview as the visual part of it (displaying all the items and properites)
My idea is to use the Listview to manage the Inventory_Items then saving each item in an INI file like I'm dooing for every other data in my App.
Please Help, It would be very kind of you
Thank you in advance
Gilles