Click here to Skip to main content
15,891,136 members
Home / Discussions / C#
   

C#

 
AnswerRe: vector based 2D line drawing Pin
Dave Kreskowiak20-Nov-18 4:31
mveDave Kreskowiak20-Nov-18 4:31 
GeneralRe: vector based 2D line drawing Pin
dataminers21-Nov-18 3:28
dataminers21-Nov-18 3:28 
AnswerRe: vector based 2D line drawing Pin
jschell21-Nov-18 7:29
jschell21-Nov-18 7:29 
Questionhow to wrok with mvc in code? Pin
Member 1406045219-Nov-18 20:23
Member 1406045219-Nov-18 20:23 
AnswerRe: how to wrok with mvc in code? Pin
OriginalGriff19-Nov-18 21:18
mveOriginalGriff19-Nov-18 21:18 
AnswerRe: how to wrok with mvc in code? Pin
Eddy Vluggen20-Nov-18 4:06
professionalEddy Vluggen20-Nov-18 4:06 
Questionc# encoding to base 64 Pin
Member 1404206419-Nov-18 1:45
Member 1404206419-Nov-18 1:45 
AnswerRe: c# encoding to base 64 Pin
OriginalGriff19-Nov-18 2:29
mveOriginalGriff19-Nov-18 2:29 
First off, Base64 is not encryption, it's translation. It doesn't provide any significant security at all, and can be translated back by anyone who can read the Base64 string.

It's a way to transfer binary data (which is eight bits wide) over a text based communications medium such as an email or HTML page. Text based data can accept a much, much smaller range of data characters - normally A-Z, a-z, 0-9, plus a small handful of special punctuation characters, many of which have special meanings in HTML or other transport documents.

So Base64 uses just 64 of those characters: A-Z, a-z, 0-9, + and /.
The reason for the decision to use just 64 characters is simple: it fits in exactly 6 bits, so it';s easy to pack 8 bits data into.
You do it by taking the least significant 6 bits of the first byte, and mapping it to the Base64 character set. You then take the other two bits, shift them 6 places right so they are in the bottom two bits, than add the least significant four bits of the second byte (by shifting them two places to the left). Translate that via the map, then shift the other four bits of byte 2 right four places to they are in the least significant bits, and add the least significant two bits of byte 3 (shifting them 4 places left), translate via the map. Finally, take the remaining 6 bits of Bytes 3, shift them right two places and map them.
You now have 4 bytes from three, which are in Base64. Repeat the process until you run out of input bytes!

Reassembly is the reverse of disassembly!
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!

AnswerRe: c# encoding to base 64 Pin
Richard Deeming19-Nov-18 2:35
mveRichard Deeming19-Nov-18 2:35 
QuestionSockets Pin
nakash18-Nov-18 13:39
nakash18-Nov-18 13:39 
AnswerRe: Sockets Pin
OriginalGriff18-Nov-18 19:57
mveOriginalGriff18-Nov-18 19:57 
GeneralRe: Sockets Pin
nakash18-Nov-18 21:17
nakash18-Nov-18 21:17 
GeneralRe: Sockets Pin
OriginalGriff18-Nov-18 21:26
mveOriginalGriff18-Nov-18 21:26 
GeneralRe: Sockets Pin
nakash18-Nov-18 22:05
nakash18-Nov-18 22:05 
AnswerRe: Sockets Pin
Eddy Vluggen19-Nov-18 0:40
professionalEddy Vluggen19-Nov-18 0:40 
GeneralRe: Sockets Pin
nakash19-Nov-18 1:41
nakash19-Nov-18 1:41 
GeneralRe: Sockets Pin
Eddy Vluggen19-Nov-18 1:59
professionalEddy Vluggen19-Nov-18 1:59 
GeneralRe: Sockets Pin
nakash19-Nov-18 3:31
nakash19-Nov-18 3:31 
GeneralRe: Sockets Pin
Eddy Vluggen19-Nov-18 3:40
professionalEddy Vluggen19-Nov-18 3:40 
Questionhow to use qr code library in my project ,i m using asp.net using C# Pin
Member 1405785317-Nov-18 4:20
Member 1405785317-Nov-18 4:20 
AnswerRe: how to use qr code library in my project ,i m using asp.net using C# Pin
Richard Andrew x6417-Nov-18 4:34
professionalRichard Andrew x6417-Nov-18 4:34 
AnswerRe: how to use qr code library in my project ,i m using asp.net using C# Pin
Dave Kreskowiak17-Nov-18 5:03
mveDave Kreskowiak17-Nov-18 5:03 
AnswerRe: how to use qr code library in my project ,i m using asp.net using C# Pin
Vikram Motwani17-Nov-18 20:27
professionalVikram Motwani17-Nov-18 20:27 
QuestionEvent handlers Pin
Member 1405777317-Nov-18 2:03
Member 1405777317-Nov-18 2:03 
AnswerRe: Event handlers Pin
OriginalGriff17-Nov-18 2:27
mveOriginalGriff17-Nov-18 2:27 

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.