Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


PROBLEM WITH LISTVIEW

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
thedebutent
Newbie cheater
Reputation: 0

Joined: 30 Dec 2015
Posts: 11

PostPosted: Wed Apr 27, 2016 11:07 am    Post subject: PROBLEM WITH LISTVIEW Reply with quote

Hello,

Here reading the position of the code:
Code:
Private Sub search()
        Dim tmpByte() As Byte = Encoding.Unicode.GetBytes("SVInventoryRemoveUnknownItems")
        Dim adresse As String = "&H" & Hex(GetMemoryAddressOfString(tmpByte, p(0))).ToString
        offset = "&H" & Hex(adresse + 1820)
        Dim valeur As String = ReadInteger(p(0).Id, offset)
        Dim lvi As New ListViewItem(offset)
        lvi.SubItems.AddRange(New String() {valeur})
        ListView1.Items.Add(lvi)
    End Sub

I want to know how to read the value 30 (B8), 51 (A8) etc .. all 3 rd position with listview?
Thank you for your help



programme.jpg
 Description:
 Filesize:  25.56 KB
 Viewed:  5266 Time(s)

programme.jpg



Sans titre.jpg
 Description:
 Filesize:  92.16 KB
 Viewed:  5266 Time(s)

Sans titre.jpg


Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Wed Apr 27, 2016 4:51 pm    Post subject: Reply with quote

Code:
For count As Integer = 1 To 10
  offset = offset + 32
  ' Repeat Your Code
Next
Back to top
View user's profile Send private message
thedebutent
Newbie cheater
Reputation: 0

Joined: 30 Dec 2015
Posts: 11

PostPosted: Thu Apr 28, 2016 7:11 am    Post subject: Reply with quote

hello,

Code:
Private Sub search()
Dim tmpByte() As Byte = Encoding.Unicode.GetBytes("SVInventoryRemoveUnknow nItems")
Dim adresse As String = "&H" & Hex(GetMemoryAddressOfString(tmpByte, p(0))).ToString
offset = "&H" & Hex(adresse + 1820)
ListView1.Items.Clear()
valeur = ReadInteger(p(0).Id, offset)
valeur2 = ReadInteger(p(0).Id, offset + 16)
Dim lvi As New ListViewItem(offset)
lvi.SubItems.AddRange(New String() {valeur})
ListView1.Items.Add(lvi)
Dim lvi2 As New ListViewItem(offset)
lvi2.SubItems.AddRange(New String() {valeur2})
ListView1.Items.Add(lvi2)
End Sub

how to simplify all 16 position values with ListView1 to avoid add lvi, lvi2 ... etc?

Why I bind the Value2 is not displayed in "lvi.SubItems.AddRange(New String() {valeur,valeur2})"?
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Thu Apr 28, 2016 10:54 am    Post subject: Reply with quote

Code:
Private Sub search()
  Dim tmpByte() As Byte = Encoding.Unicode.GetBytes("SVInventoryRemoveUnknow nItems")
  Dim adresse As String = "&H" & Hex(GetMemoryAddressOfString(tmpByte, p(0))).ToString
  offset = "&H" & Hex(adresse + 1820)
  ListView1.Items.Clear()
  For count As Integer = 1 To 10
    valeur = ReadInteger(p(0).Id, offset)
    Dim lvi As New ListViewItem(offset)
    lvi.SubItems.AddRange(New String() {valeur})
    ListView1.Items.Add(lvi)
    offset = offset + 16
  Next
End Sub
Back to top
View user's profile Send private message
thedebutent
Newbie cheater
Reputation: 0

Joined: 30 Dec 2015
Posts: 11

PostPosted: Sun May 01, 2016 9:59 am    Post subject: Reply with quote

I found my problem solution.

Code:
For k = 0 To 100 Step 16
                valeur = ReadInteger(p(0).Id, offset + k)
                Dim lvi As New ListViewItem("&H" & Hex(offset + k))
                lvi.SubItems.AddRange(New String() {valeur})
                ListView1.Items.Add(lvi)
            Next k


Thank you for your help
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites