Click here to Skip to main content
15,910,981 members
Home / Discussions / C#
   

C#

 
QuestionExtract RSAParameters from custom Private Key Pin
Member 1508150323-Feb-21 21:09
Member 1508150323-Feb-21 21:09 
AnswerRe: Extract RSAParameters from custom Private Key Pin
Gerry Schmitz24-Feb-21 8:50
mveGerry Schmitz24-Feb-21 8:50 
GeneralRe: Extract RSAParameters from custom Private Key Pin
Member 1508150324-Feb-21 18:33
Member 1508150324-Feb-21 18:33 
AnswerRe: Extract RSAParameters from custom Private Key Pin
Member 1508430525-Feb-21 15:42
Member 1508430525-Feb-21 15:42 
QuestionUsing azure storage account to share file with multiple users Pin
Lmathew22-Feb-21 19:06
Lmathew22-Feb-21 19:06 
AnswerRe: Using azure storage account to share file with multiple users Pin
Gerry Schmitz22-Feb-21 19:11
mveGerry Schmitz22-Feb-21 19:11 
QuestionAsync task Pin
Kenneth Haugland20-Feb-21 6:01
mvaKenneth Haugland20-Feb-21 6:01 
QuestionRe: Async task Pin
Eddy Vluggen20-Feb-21 12:51
professionalEddy Vluggen20-Feb-21 12:51 
AnswerRe: Async task Pin
Kenneth Haugland20-Feb-21 23:57
mvaKenneth Haugland20-Feb-21 23:57 
GeneralRe: Async task Pin
Dave Kreskowiak21-Feb-21 5:10
mveDave Kreskowiak21-Feb-21 5:10 
GeneralRe: Async task Pin
Kenneth Haugland21-Feb-21 8:10
mvaKenneth Haugland21-Feb-21 8:10 
GeneralRe: Async task Pin
Richard Deeming21-Feb-21 22:19
mveRichard Deeming21-Feb-21 22:19 
GeneralRe: Async task Pin
Kenneth Haugland22-Feb-21 6:58
mvaKenneth Haugland22-Feb-21 6:58 
GeneralRe: Async task Pin
Richard Deeming21-Feb-21 22:19
mveRichard Deeming21-Feb-21 22:19 
GeneralRe: Async task Pin
Dave Kreskowiak22-Feb-21 3:42
mveDave Kreskowiak22-Feb-21 3:42 
Questionc# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge18-Feb-21 22:00
Roberto64_Ge18-Feb-21 22:00 
AnswerRe: c# OPCgroup.SyncWrite vs. Float type Pin
OriginalGriff18-Feb-21 22:38
mveOriginalGriff18-Feb-21 22:38 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge19-Feb-21 0:24
Roberto64_Ge19-Feb-21 0:24 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
OriginalGriff19-Feb-21 0:55
mveOriginalGriff19-Feb-21 0:55 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge19-Feb-21 1:41
Roberto64_Ge19-Feb-21 1:41 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
OriginalGriff19-Feb-21 1:58
mveOriginalGriff19-Feb-21 1:58 
Doubles and floats have the same problem: for example 0.1 and 0.2 can't be stored in a floating point format because they are a recurring number in binary, so 0.1 + 0.2 != 0.3:
C#
float fp1 = 0.1F;
float fp2 = 0.2F;
string result = (fp1 + fp2) == 0.3F ? "Yes" : "No";
Debug.WriteLine($"{fp1} + {fp2} = 0.3? {result}");
double dp1 = 0.1;
double dp2 = 0.2;
result = (dp1 + dp2) == 0.3 ? "Yes" : "No";
Debug.WriteLine($"{dp1} + {dp2} = 0.3? {result}");
Will give you:
0.1 + 0.2 = 0.3? No
0.1 + 0.2 = 0.3? No


I suspect that decimal may help, but to be honest I have no idea what you are trying to achieve, or what values you are actually looking at and expecting, do I can't recommend them as a "fix".
"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: c# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge19-Feb-21 2:28
Roberto64_Ge19-Feb-21 2:28 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge19-Feb-21 8:27
Roberto64_Ge19-Feb-21 8:27 
GeneralRe: c# OPCgroup.SyncWrite vs. Float type Pin
Roberto64_Ge23-Feb-21 0:53
Roberto64_Ge23-Feb-21 0:53 
QuestionWinforms Usercontrol Databinding question Pin
Member 1501196518-Feb-21 5:20
Member 1501196518-Feb-21 5:20 

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.