Click here to Skip to main content
15,919,778 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: How to prevent user click to the checkbox on a listview control Pin
[N][Q][H]17-Oct-09 16:40
[N][Q][H]17-Oct-09 16:40 
GeneralRe: How to prevent user click to the checkbox on a listview control Pin
Richard MacCutchan17-Oct-09 21:27
mveRichard MacCutchan17-Oct-09 21:27 
AnswerRe: How to prevent user click to the checkbox on a listview control Pin
vsaratkar19-Oct-09 7:29
vsaratkar19-Oct-09 7:29 
QuestionHow do I create an unstopable thread? Pin
Paulo Zemek15-Oct-09 13:19
Paulo Zemek15-Oct-09 13:19 
AnswerRe: How do I create an unstopable thread? Pin
Dave Kreskowiak16-Oct-09 5:23
mveDave Kreskowiak16-Oct-09 5:23 
QuestionAny chance of reversing the encoding Pin
cristi82gt15-Oct-09 6:03
cristi82gt15-Oct-09 6:03 
AnswerRe: Any chance of reversing the encoding Pin
Dave Kreskowiak15-Oct-09 7:55
mveDave Kreskowiak15-Oct-09 7:55 
GeneralRe: Any chance of reversing the encoding Pin
cristi82gt15-Oct-09 8:35
cristi82gt15-Oct-09 8:35 
Thanks for the answer Dave. Well i don't want to bring the text files to the way they were before, only the other types of files (jpeg, pdf).
Let's neglect for a little the function ReplaceInFile , because the expression to replace was pretty long (around 60-70 characters) and i don't think that in an image read as text would find it(very improbably)

The problem is that i read an binary file(for example an image-JPEG) with a StreamReader (UTF8 encoding) as a string, than i wrote that text with a StreamWriter overwriting the original file. (the function i wrote was clearly meant for text file but i forgot to limit it only to those type of files)

The problem is that the image file is now unreadable because it has been written as a text file with UTF8 encoding. I know that in case of Base64Encoding reading a binary file as text wouldn't be a problem, because the text can be reverted back to bytes so that would again compose a valid image(jpeg) for example

In the case i did i don't think this is possible. Any ideas?
GeneralRe: Any chance of reversing the encoding Pin
Dave Kreskowiak15-Oct-09 8:46
mveDave Kreskowiak15-Oct-09 8:46 
GeneralRe: Any chance of reversing the encoding Pin
cristi82gt15-Oct-09 8:52
cristi82gt15-Oct-09 8:52 
Question???Some function exists: Pin
GuilleB0914-Oct-09 9:46
GuilleB0914-Oct-09 9:46 
AnswerRe: ???Some function exists: Pin
Abhijit Jana14-Oct-09 17:10
professionalAbhijit Jana14-Oct-09 17:10 
QuestionHow to refresh the child window dropdown Pin
sandhya1413-Oct-09 19:53
sandhya1413-Oct-09 19:53 
AnswerRe: How to refresh the child window dropdown Pin
Shameel19-Oct-09 0:02
professionalShameel19-Oct-09 0:02 
QuestionCloning winforms Pin
Starkie7013-Oct-09 9:01
Starkie7013-Oct-09 9:01 
AnswerRe: Cloning winforms Pin
Henry Minute13-Oct-09 10:11
Henry Minute13-Oct-09 10:11 
Questionhow do my Windows forms buttons change their border appearance at runtime? Pin
mnemonic6913-Oct-09 0:41
mnemonic6913-Oct-09 0:41 
AnswerRe: how do my Windows forms buttons change their border appearance at runtime? Pin
Richard MacCutchan13-Oct-09 1:14
mveRichard MacCutchan13-Oct-09 1:14 
GeneralRe: how do my Windows forms buttons change their border appearance at runtime? Pin
mnemonic6913-Oct-09 2:12
mnemonic6913-Oct-09 2:12 
GeneralRe: how do my Windows forms buttons change their border appearance at runtime? Pin
Richard MacCutchan13-Oct-09 2:54
mveRichard MacCutchan13-Oct-09 2:54 
AnswerRe: how do my Windows forms buttons change their border appearance at runtime? Pin
Shameel19-Oct-09 0:05
professionalShameel19-Oct-09 0:05 
QuestionSQL Command Wrapper class and configuration instance in web.config Pin
NICE TO MEET13-Oct-09 0:29
NICE TO MEET13-Oct-09 0:29 
QuestionStored procedure Pin
krishnaveer12-Oct-09 21:36
krishnaveer12-Oct-09 21:36 
AnswerRe: Stored procedure Pin
Pete O'Hanlon12-Oct-09 21:52
mvePete O'Hanlon12-Oct-09 21:52 
QuestionWPF DataGrid without database Pin
Nick Alexeev12-Oct-09 9:57
professionalNick Alexeev12-Oct-09 9:57 

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.