Версия для печати темы
Нажмите сюда для просмотра этой темы в оригинальном формате
Форум программистов > VB6 > Search folders, subfolders and subsubfolders...


Автор: Newbee 24.7.2003, 11:40
I'm writing the programm which looks for the folder in Database, then for subfolders of this folder, then subsubfolder.... I have three columns in table: id, parentid and name.
1) Find folder:
SQLQuery = ("SELECT id FROM table WHERE name=" & txtEnterName.Text & "'")
txtDataid.Text = id
2) When I receive ID I have to look in parentid colum whether this folder has subfolders:
SQLQuery1 = ("SELECT id FROM table WHERE parentid='" & txtDataid.Text & "'")
3) etc..... smile.gif
Maybe someone has code with recursive function? Help! adv/help.gif

P.S. Sorry, I must write English, because I don't have Russian keyboard, I don't know blind method and I hate "translit". confused.gif

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)