Click here to Skip to main content
15,893,790 members
Home / Discussions / C#
   

C#

 
GeneralRe: Floating point conversion with error Pin
Ismael Oliveira 20212-Aug-21 15:45
Ismael Oliveira 20212-Aug-21 15:45 
AnswerRe: Floating point conversion with error Pin
Richard MacCutchan1-Aug-21 21:51
mveRichard MacCutchan1-Aug-21 21:51 
GeneralRe: Floating point conversion with error Pin
Ismael Oliveira 20212-Aug-21 15:59
Ismael Oliveira 20212-Aug-21 15:59 
AnswerRe: Floating point conversion with error Pin
jsc422-Aug-21 1:21
professionaljsc422-Aug-21 1:21 
GeneralRe: Floating point conversion with error Pin
Ismael Oliveira 20212-Aug-21 15:58
Ismael Oliveira 20212-Aug-21 15:58 
QuestionMake a control invisible Pin
Ismael Oliveira 202131-Jul-21 14:56
Ismael Oliveira 202131-Jul-21 14:56 
AnswerRe: Make a control invisible Pin
Gerry Schmitz31-Jul-21 17:03
mveGerry Schmitz31-Jul-21 17:03 
AnswerRe: Make a control invisible Pin
OriginalGriff31-Jul-21 19:19
mveOriginalGriff31-Jul-21 19:19 
GeneralRe: Make a control invisible Pin
Ismael Oliveira 20211-Aug-21 12:57
Ismael Oliveira 20211-Aug-21 12:57 
AnswerRe: Make a control invisible Pin
Mycroft Holmes1-Aug-21 12:17
professionalMycroft Holmes1-Aug-21 12:17 
GeneralRe: Make a control invisible Pin
Gerry Schmitz2-Aug-21 7:45
mveGerry Schmitz2-Aug-21 7:45 
GeneralRe: Make a control invisible Pin
Mycroft Holmes2-Aug-21 13:52
professionalMycroft Holmes2-Aug-21 13:52 
GeneralRe: Make a control invisible Pin
BillWoodruff20-Aug-21 6:50
professionalBillWoodruff20-Aug-21 6:50 
QuestionError handling when using Invoke method Pin
Alex Dunlop31-Jul-21 5:49
Alex Dunlop31-Jul-21 5:49 
AnswerRe: Error handling when using Invoke method Pin
Richard MacCutchan31-Jul-21 21:04
mveRichard MacCutchan31-Jul-21 21:04 
QuestionHow to pass a variable inside Try{} to outside of it? Pin
Alex Dunlop30-Jul-21 23:05
Alex Dunlop30-Jul-21 23:05 
AnswerRe: How to pass a variable inside Try{} to outside of it? Pin
OriginalGriff30-Jul-21 23:27
mveOriginalGriff30-Jul-21 23:27 
AnswerRe: How to pass a variable inside Try{} to outside of it? Pin
Victor Nijegorodov30-Jul-21 23:28
Victor Nijegorodov30-Jul-21 23:28 
QuestionitextSharp with C# Pin
Ismael Oliveira 202129-Jul-21 6:08
Ismael Oliveira 202129-Jul-21 6:08 
AnswerRe: itextSharp with C# Pin
Dave Kreskowiak29-Jul-21 6:33
mveDave Kreskowiak29-Jul-21 6:33 
GeneralRe: itextSharp with C# Pin
Ismael Oliveira 202131-Jul-21 14:50
Ismael Oliveira 202131-Jul-21 14:50 
GeneralRe: itextSharp with C# Pin
Dave Kreskowiak31-Jul-21 15:05
mveDave Kreskowiak31-Jul-21 15:05 
QuestionHow to create filtering for DataTable based on toggle switches? Pin
Alex Dunlop27-Jul-21 21:46
Alex Dunlop27-Jul-21 21:46 
AnswerRe: How to create filtering for DataTable based on toggle switches? Pin
OriginalGriff27-Jul-21 21:53
mveOriginalGriff27-Jul-21 21:53 
I don't think string interpolation will work there: interpolated strings are a syntactic sugar for the older method using numbered parameters and are evaluated when the interpolated string is constructed, not when it is used:
C#
using System;

public class Program
	{
	static string name = "???";
	static string xxx = $"Hello {name}!";
	static string yyy = "Hello {0}!";
	public static void Main()
	{
		name = "Paul";
		Console.WriteLine($"Hello {name}!");
		Console.WriteLine(xxx);
		Console.WriteLine(yyy, name);
	}
}
Will give you:
Hello Paul!
Hello ???!
Hello Paul!
So setting a RowFilter to the value of a variable doesn't mean that it will change the View at all whcn checks change: it will only use the values at the moment when the string is created.

What you need to do is change the filter each time the user changes the check boxes.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!

GeneralRe: How to create filtering for DataTable based on toggle switches? Pin
Alex Dunlop27-Jul-21 22:03
Alex Dunlop27-Jul-21 22:03 

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.