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

C#

 
AnswerRe: operate the pc through voice command in c# Pin
Eddy Vluggen22-Feb-11 9:37
professionalEddy Vluggen22-Feb-11 9:37 
AnswerRe: operate the pc through voice command in c# Pin
_Maxxx_22-Feb-11 15:31
professional_Maxxx_22-Feb-11 15:31 
GeneralRe: operate the pc through voice command in c# Pin
aeman23-Feb-11 6:49
aeman23-Feb-11 6:49 
AnswerRe: operate the pc through voice command in c# Pin
Member 873075321-Apr-12 11:26
Member 873075321-Apr-12 11:26 
QuestionIframe page login not working fine in IE...,But working fine in Mozila browser..., Pin
Member 387988122-Feb-11 1:22
Member 387988122-Feb-11 1:22 
AnswerRe: Iframe page login not working fine in IE...,But working fine in Mozila browser..., Pin
Peter_in_278022-Feb-11 15:54
professionalPeter_in_278022-Feb-11 15:54 
QuestionHow to display Warning Message When Uploading a File.. Pin
Rocky2322-Feb-11 0:18
Rocky2322-Feb-11 0:18 
AnswerRe: How to display Warning Message When Uploading a File.. Pin
Luc Pattyn22-Feb-11 0:32
sitebuilderLuc Pattyn22-Feb-11 0:32 
you first would have to define "open". is it "open" at the functional level (like Notepad or Word is showing the text content), or is it the state the file has from File.Open() to File.Close()?

In the former case, it may or may not be doable. Notepad reads an entire text file and closes it while you can edit it (Proof: open a .txt file and try and delete it while you can edit it in Notepad); Word OTOH keeps the file locked, so you can't delete it while editing.

In the latter case, a File.Delete() would fail. So you could do this:
- make a copy of the file;
- try and delete the original;
- if that succeeds, it was not in use, and you should rename the copy to the original;
- if it fails, the file was not entirely free (either in use, locked, write-protected, ...).

Conclusion: there is no general solution.

Remark: if the upload and the edit could be combined in a single app, then of course that app would know what it is doing, so it could prohibit an upload while editing.

Smile | :)
Luc Pattyn [Forum Guidelines] [My Articles] Nil Volentibus Arduum
Please use <PRE> tags for code snippets, they preserve indentation, improve readability, and make me actually look at the code.

GeneralRe: How to display Warning Message When Uploading a File.. [modified] Pin
Bernhard Hiller22-Feb-11 20:31
Bernhard Hiller22-Feb-11 20:31 
GeneralRe: How to display Warning Message When Uploading a File.. [Code Updated] Pin
Rocky2322-Feb-11 23:18
Rocky2322-Feb-11 23:18 
QuestionPreventing MDI child form from losing focus Pin
Dewald21-Feb-11 23:24
Dewald21-Feb-11 23:24 
AnswerRe: Preventing MDI child form from losing focus Pin
Mycroft Holmes22-Feb-11 0:07
professionalMycroft Holmes22-Feb-11 0:07 
GeneralRe: Preventing MDI child form from losing focus Pin
Wayne Gaylard22-Feb-11 0:44
professionalWayne Gaylard22-Feb-11 0:44 
GeneralRe: Preventing MDI child form from losing focus Pin
Dewald22-Feb-11 0:51
Dewald22-Feb-11 0:51 
GeneralRe: Preventing MDI child form from losing focus Pin
Mycroft Holmes22-Feb-11 11:00
professionalMycroft Holmes22-Feb-11 11:00 
GeneralRe: Preventing MDI child form from losing focus Pin
Dewald22-Feb-11 19:03
Dewald22-Feb-11 19:03 
GeneralRe: Preventing MDI child form from losing focus Pin
Mycroft Holmes22-Feb-11 19:34
professionalMycroft Holmes22-Feb-11 19:34 
GeneralRe: Preventing MDI child form from losing focus Pin
Dewald22-Feb-11 19:45
Dewald22-Feb-11 19:45 
QuestionGet IP address on a LAN [modified] Pin
Mc_Topaz21-Feb-11 23:14
Mc_Topaz21-Feb-11 23:14 
AnswerRe: Get all IP address on a LAN Pin
Rob Philpott21-Feb-11 23:32
Rob Philpott21-Feb-11 23:32 
GeneralRe: Get all IP address on a LAN Pin
Mc_Topaz21-Feb-11 23:43
Mc_Topaz21-Feb-11 23:43 
GeneralRe: Get all IP address on a LAN Pin
Rob Philpott22-Feb-11 1:39
Rob Philpott22-Feb-11 1:39 
AnswerRe: Get IP address on a LAN Pin
OriginalGriff21-Feb-11 23:36
mveOriginalGriff21-Feb-11 23:36 
Questionhandle data in GUI (datagridview) and database Pin
Ronenb21-Feb-11 21:29
Ronenb21-Feb-11 21:29 
AnswerRe: handle data in GUI (datagridview) and database Pin
OriginalGriff21-Feb-11 21:48
mveOriginalGriff21-Feb-11 21:48 

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.