Click here to Skip to main content
15,922,696 members
Home / Discussions / C#
   

C#

 
AnswerRe: textbox input Pin
BillWoodruff3-Mar-18 14:31
professionalBillWoodruff3-Mar-18 14:31 
GeneralRe: textbox input Pin
User 136751143-Mar-18 23:56
User 136751143-Mar-18 23:56 
GeneralRe: textbox input PinPopular
OriginalGriff4-Mar-18 1:21
mveOriginalGriff4-Mar-18 1:21 
GeneralRe: textbox input Pin
BillWoodruff4-Mar-18 2:18
professionalBillWoodruff4-Mar-18 2:18 
GeneralRe: textbox input Pin
Luc Pattyn4-Mar-18 7:19
sitebuilderLuc Pattyn4-Mar-18 7:19 
GeneralRe: textbox input Pin
OriginalGriff4-Mar-18 19:27
mveOriginalGriff4-Mar-18 19:27 
GeneralRe: textbox input Pin
Pete O'Hanlon4-Mar-18 20:56
mvePete O'Hanlon4-Mar-18 20:56 
GeneralRe: textbox input Pin
OriginalGriff4-Mar-18 21:04
mveOriginalGriff4-Mar-18 21:04 
GeneralRe: textbox input Pin
Pete O'Hanlon4-Mar-18 21:10
mvePete O'Hanlon4-Mar-18 21:10 
QuestionHow to create a recursive lambda function ? Pin
Jesus Carroll2-Mar-18 12:26
professionalJesus Carroll2-Mar-18 12:26 
AnswerRe: How to create a recursive lambda function ? PinPopular
Eddy Vluggen2-Mar-18 12:32
professionalEddy Vluggen2-Mar-18 12:32 
PraiseRe: How to create a recursive lambda function ? Pin
Jesus Carroll2-Mar-18 12:48
professionalJesus Carroll2-Mar-18 12:48 
GeneralRe: How to create a recursive lambda function ? Pin
Eddy Vluggen2-Mar-18 13:05
professionalEddy Vluggen2-Mar-18 13:05 
AnswerRe: How to create a recursive lambda function ? Pin
jschell3-Mar-18 11:00
jschell3-Mar-18 11:00 
AnswerRe: How to create a recursive lambda function ? Pin
Richard Deeming5-Mar-18 8:08
mveRichard Deeming5-Mar-18 8:08 
QuestionMove Up And Down rows in datagridview and update it in database Pin
Member 133258462-Mar-18 10:49
Member 133258462-Mar-18 10:49 
AnswerRe: Move Up And Down rows in datagridview and update it in database Pin
Eddy Vluggen2-Mar-18 12:34
professionalEddy Vluggen2-Mar-18 12:34 
GeneralRe: Move Up And Down rows in datagridview and update it in database Pin
Member 133258462-Mar-18 23:53
Member 133258462-Mar-18 23:53 
GeneralRe: Move Up And Down rows in datagridview and update it in database Pin
Eddy Vluggen3-Mar-18 2:34
professionalEddy Vluggen3-Mar-18 2:34 
GeneralRe: Move Up And Down rows in datagridview and update it in database Pin
Member 133258463-Mar-18 18:47
Member 133258463-Mar-18 18:47 
GeneralRe: Move Up And Down rows in datagridview and update it in database Pin
Eddy Vluggen4-Mar-18 1:41
professionalEddy Vluggen4-Mar-18 1:41 
QuestionUse from dataReader to bind data to a data gridview Pin
Member 133258462-Mar-18 10:38
Member 133258462-Mar-18 10:38 
AnswerRe: Use from dataReader to bind data to a data gridview Pin
Eddy Vluggen2-Mar-18 12:35
professionalEddy Vluggen2-Mar-18 12:35 
GeneralRe: Use from dataReader to bind data to a data gridview Pin
Member 133258463-Mar-18 0:06
Member 133258463-Mar-18 0:06 
SuggestionRe: Use from dataReader to bind data to a data gridview Pin
Richard Deeming5-Mar-18 8:02
mveRichard Deeming5-Mar-18 8:02 
Member 13325846 wrote:
new OleDBCammand(“Select *From[“+txtBox1.Text+”]”,con)

That code is vulnerable to SQL Injection[^]. Unfortunately, there's no easy way to fix it, since you can't use a parameter as a table name.

Rather than letting the user type in any table name, it would be better to give them a drop-down list of tables to choose from. After all, not every table in your database is going to have Id and Name columns.

It would also be better to only load the specific columns you need, rather than using SELECT * FROM ...



"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer


General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.