Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: C# ASP.NET CSS jQuery menu database , +
I am sorry for my poor english!
i have this imageDB
database and i want generate this format
by c# and from this table please help me it's urgent.
Posted 14-Jul-12 11:22am
Edited 14-Jul-12 11:27am
Abdul Quader Mamun at 14-Jul-12 22:05pm
you need to little bit work with the code.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

System.Data.SqlClient.SqlConnection con = new System.Data.SqlClient.SqlConnection("connectionStringHere");
System.Data.SqlClient.SqlCommand cmd = new System.Data.SqlClient.SqlCommand();
cmd.Connection = con;
cmd.CommandType = CommandType.StoredProcedure;
//you need to customize sp as you want
cmd.CommandText = "sp_Here";
System.Data.SqlClient.SqlDataReader reader;
reader = cmd.ExecuteReader();
System.Text.StringBuilder sb=new System.Text.StringBuilder() 
//you need to customize this as you want
sb.AppenedFormat("<li>{0}</li>"  reader.GetString(0));
Try with this code.
Behnam Mohammadi at 15-Jul-12 14:54pm
Thank you very much.
But I want the menu to be made. The following sub-menu to the menu each time to be unlimited.
Such as content management systems.
If someone put the video in my top tips to help me get much thanks.
Very essential and urgent need
Thank you very much.
Abdul Quader Mamun at 15-Jul-12 15:18pm
here is an example of parent-child or upto infinity. try with this
Behnam Mohammadi at 24-Jul-12 11:46am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 8,373
1 OriginalGriff 6,466
2 Peter Leow 3,567
3 Zoltán Zörgő 3,316
4 Richard MacCutchan 2,397

Advertise | Privacy | Mobile
Web02 | 2.8.150123.1 | Last Updated 15 Jul 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100