Since you want 2 particular names to go last, I assume you know how to sort the results, but want the whole field sorted ascending and out of sort those 2 names in the bottom.
I'll give you an example for 2 names hardcoded and you can modify it with params or with another table or whatever.
[CODE] select EmpID,EmpName from Emp
order by case when EmpName in ('testName1','testName2') then 2 else 1 end,EmpName[/CODE]

sknake commented: you got it +14

or use
[CODE] if i < ListBox1.Items.Count - 1 then textbox6.text &= "," [/CODE]
to insert the comma (,) character.

I'm sorry arjen, but I'm not going to help you build a keylogger or anything similar.
Each person has a right to his/hers privacy and I am not going to help you violate that.

Since you are new to this, a small hint:
If you get lost with the nested IFs and can't tell where each else (or end if) goes to which if, it might help you to add a comment at the end of the line starting the if with a number. Use the same number for the matching end if and you know where each if starts and ends.

Like this:
if 1=1 ' 1
if 2=2 ' 2
if 3=3 '3

end if '3
else ' 2
if a=a ' 4

else '4

end if '4
end if '2

else '1
end if ' 1 [/CODE]

codeorder commented: +=1 for comments. :) +10

Again why don't you use the textbox.lostfocus event in the last textbox to run your function?

PS: Did you try both the e.Handled = True and the e.SuppressKeyPress = True properties of System.Windows.Forms.KeyEventArgs and both failed to suppress the Tab? Here's another page with 3 more examples on the same topic: [url][/url]

Like debasisdas said, yes you can. But this won't delete the record from both tables, if that's what you had in mind. It's use is to delete from grp_performance, using c.cat_name as an example.

If you need to delete from both tables with 1 delete, you will need a trigger.

debasisdas commented: agree +13

I'm guessing the program you want to hide is the keylogger in your previous post?

codeorder commented: :D, was thinking the same. +10