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

C#

 
GeneralRe: DataSet: no MoveNext or any indexing at all Pin
James T. Johnson17-Apr-02 11:51
James T. Johnson17-Apr-02 11:51 
GeneralRe: DataSet: no MoveNext or any indexing at all Pin
18-Apr-02 4:34
suss18-Apr-02 4:34 
QuestionSaving class instance to file?? Pin
HG17-Apr-02 9:41
HG17-Apr-02 9:41 
AnswerRe: Saving class instance to file?? Pin
James T. Johnson17-Apr-02 11:43
James T. Johnson17-Apr-02 11:43 
GeneralLogicalDrives Pin
Mazdak17-Apr-02 9:32
Mazdak17-Apr-02 9:32 
GeneralRe: LogicalDrives Pin
Nick Parker17-Apr-02 9:57
protectorNick Parker17-Apr-02 9:57 
GeneralRe: LogicalDrives Pin
Mazdak18-Apr-02 5:21
Mazdak18-Apr-02 5:21 
GeneralFileAttribute Pin
Mazdak17-Apr-02 8:05
Mazdak17-Apr-02 8:05 
I have a file and waana check if it has ReadOnly attribute,if its true change it to write in it. I use this code:

if(File.GetAttributes(filename) == FileAttributes.ReadOnly)
  File.SetAttributes( filename , FileAttributes.Normal );

FileStream myfile = File.Open( filename ,System.IO.FileMode.Open  , System.IO.FileAccess.ReadWrite );

//write something in the file


But when it reached to readonly file it does not change the ReadOnly attribute.

Mazy

"The path you tread is narrow and the drop is shear and very high,
The ravens all are watching from a vantage point near by,
Apprehension creeping like a choo-train uo your spine,
Will the tightrope reach the end;will the final cuplet rhyme?"Cymbaline-Pink Floyd

GeneralRe: FileAttribute Pin
James T. Johnson17-Apr-02 12:43
James T. Johnson17-Apr-02 12:43 
GeneralRe: FileAttribute Pin
Mazdak18-Apr-02 5:22
Mazdak18-Apr-02 5:22 
QuestionF1 Help? Pin
Neo Anderson17-Apr-02 6:28
Neo Anderson17-Apr-02 6:28 
AnswerRe: F1 Help? Pin
James T. Johnson17-Apr-02 15:00
James T. Johnson17-Apr-02 15:00 
GeneralAVI Pin
17-Apr-02 5:29
suss17-Apr-02 5:29 
GeneralRe: AVI Pin
James T. Johnson17-Apr-02 16:38
James T. Johnson17-Apr-02 16:38 
GeneralRe: AVI Pin
Mike Nordell17-Apr-02 17:35
Mike Nordell17-Apr-02 17:35 
GeneralXor() Pin
Mazdak17-Apr-02 5:13
Mazdak17-Apr-02 5:13 
GeneralRe: Xor() Pin
James T. Johnson17-Apr-02 5:54
James T. Johnson17-Apr-02 5:54 
GeneralRe: Xor() Pin
Mazdak17-Apr-02 7:04
Mazdak17-Apr-02 7:04 
GeneralI don't have topic for this Pin
Mazdak17-Apr-02 3:44
Mazdak17-Apr-02 3:44 
GeneralRe: I don't have topic for this Pin
Rüpel18-Apr-02 2:15
Rüpel18-Apr-02 2:15 
GeneralRe: I don't have topic for this Pin
Mazdak18-Apr-02 5:23
Mazdak18-Apr-02 5:23 
GeneralRe: I don't have topic for this Pin
James T. Johnson18-Apr-02 5:53
James T. Johnson18-Apr-02 5:53 
GeneralWinForm Datagrid Control Pin
17-Apr-02 3:27
suss17-Apr-02 3:27 
GeneralRe: WinForm Datagrid Control Pin
James T. Johnson17-Apr-02 15:12
James T. Johnson17-Apr-02 15:12 
Generalmemstream to listview icon Pin
SimonS16-Apr-02 23:00
SimonS16-Apr-02 23:00 

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.