what is the syntax for blank list view object... for example:

if classlistview is blank then
<statement>
else
<statement>
end if

what is the syntax for classlistview is blank? as in no record(s) were retrieved...
any help is appreciated... thanks :)

ListView1.Items.Count ' Its for count the element

'So check it

if Listview1.Items.Count<1 then
<statement>
else
<statement>
end if

try this code :)

If ListBox1.Items.Count = 0 Then

        Else

        End If

thanks kingsonprisonic and waqasaslammmeo... :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.18 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.