Tutorials to .com

Tutorials to .com » Dotnet » Winform » The use of unlimited-class extension of TreeView nodes (original)

The use of unlimited-class extension of TreeView nodes (original)

Print View , by: iSee ,Total views: 12 ,Word Count: 387 ,Date: Sat, 22 Aug 2009 Time: 10:10 AM

Function requirements:

vb.net and oracle9i operating environment

As a result of a large amount of data, so can not use the result set rs read out, in the treeview nodes to fill.

Tree nodes need to fill in data fields in the form of "." Partition

Such as: 01 01.01 01.02 01.01.01 02 02.01 02.01 ............................

Instr function using its own oracle, you can press "." Partition number. And return the required result set, initialized to load non-reads. "" Field, the first reading with a "." ... ... ... ...

As to the sqlserver database with the oracle to write a slightly different function, one can go to google, csdn to find such places.

sql statement broadly written as follows:

If pDotCount = 0 Then
sqlString = "select t. was necessary to split the field, t.cname from table t where Instr (t.icsn,''''.'''', 1, 1) = 0"
Else
sqlString = "select t. was necessary to split the field, t.cname from table t where Instr (t.icsn,''''.'''', 1," & pDotCount & ")> 0 and Instr (t . icsn,''''.'''', 1, "& (pDotCount + 1) &") = 0 and Instr (t.icsn ,''''" & pParent & "'''', 1, 1) = 1 "
End If

pDotCount need to read the field "." the number of

And then by double-clicking the event was the father of the node (the node is selected), sql statement pParent, to return to the parent node is a subset of the nodes, so that one can double-click an unlimited expansion of the data up until the last layer of until

Search position any node

The main node is the initial choice of location. Omitted here, who are interested can contact me directly and, learn from each other.

MSN: yun15291li@hotmail.com

Email: ygyunguang@yahoo.com.cn



.Net Windows development Articles


Can't Find What You're Looking For?


Rating: Not yet rated

Comments

No comments posted.