I have a textbox in which users can put their notes and then I am showing those notes on the right hand side in the same page. Now in my DB I have columns:
-UserName
-Notes
Now here is the code to get the notes using LINQ2SQL:
int getName = Int16.Parse(Session["Selected"].ToString());
var showNotes = from r in em.Test
where r.Name == getName
select r.Note;
var showUser = from r in em.Test
where r.Name == getName
select r.UserName;
tbShowNote.Text = String.Join(Environment.NewLine, showNotes);
tbShowNote.Text = String.Join(Environment.NewLine, showUser);
This one shows me the UserName but not the Note. I want to show something like this:
- This is a Test Note. -UserName1