Click here to Skip to main content
15,898,134 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: error in m_DateStart.SetFormat("MM/dd/yyy"); Pin
ThatsAlok9-Jul-06 20:33
ThatsAlok9-Jul-06 20:33 
GeneralRe: error in m_DateStart.SetFormat("MM/dd/yyy"); [modified] Pin
Tara149-Jul-06 21:16
Tara149-Jul-06 21:16 
QuestionFAX management programatically Pin
Rilhas9-Jul-06 3:11
Rilhas9-Jul-06 3:11 
QuestionADO.NET in MFC 6 Pin
Shai`tan9-Jul-06 2:42
Shai`tan9-Jul-06 2:42 
AnswerRe: ADO.NET in MFC 6 Pin
Nemanja Trifunovic9-Jul-06 3:12
Nemanja Trifunovic9-Jul-06 3:12 
QuestionCTabCtrl with centre justified tabs. Pin
Yokeldj9-Jul-06 1:41
Yokeldj9-Jul-06 1:41 
QuestionsharingViolation error Pin
paperke679-Jul-06 1:22
paperke679-Jul-06 1:22 
AnswerRe: sharingViolation error [modified] Pin
bob169729-Jul-06 9:15
bob169729-Jul-06 9:15 
paperke67 wrote:
When I run both applications, I sometimes receive the follow message


If this is in your debug output window, it's just informaing you that your try/catch is working correctly. If your using the same filename/path for each application, then I would expect an exception to occur periodically as a matter of statistic.

You did not post a Try/catch with the first apps code but I'm guessing its around the actual code, otherwise I would expect an exception dialog box to pop up on you for the same reason.

Since you are simply ignoring the exception by deleting the CException pointer without reporting it, it would appear that suppressing the error is by design and what you intended so any indication of a first chance exception in the debug output window for file operations is likely just informative and should cause you no alarm or indicate any problems with your code.

-- modified at 15:16 Sunday 9th July, 2006

I guess I forgot to mention that based on what your doing, two apps are competing to open the same file exclusively and since there is no syncronization between the apps and there are certain lag times on file locking operations, that the exception is expected to occur and again is just the nature of the beast when dealing with files, databases, or any resource that could be unavailable for a moment based on inherent environmental conditions. One of the competing apps is bound to find the file locked from time to time and it is safe to simply ignore it, and try again on the next interval or timer.

NOTE: However, if the file remains locked indefinitely, You app will not indicate this problem to the user since it is happily ignoring the exception every time. You might want to keep track of failures and after some excessive period report an error to a log file or popup an error via the GUI.
GeneralRe: sharingViolation error Pin
earl10-Jul-06 5:02
earl10-Jul-06 5:02 
GeneralRe: sharingViolation error Pin
bob1697210-Jul-06 10:52
bob1697210-Jul-06 10:52 
GeneralRe: sharingViolation error Pin
earl10-Jul-06 11:13
earl10-Jul-06 11:13 
QuestionCRichEdit right click Pin
YaronNir8-Jul-06 22:48
YaronNir8-Jul-06 22:48 
QuestionCreating a custom control? Pin
Lord Kixdemp8-Jul-06 16:45
Lord Kixdemp8-Jul-06 16:45 
AnswerRe: Creating a custom control? Pin
Sarath C9-Jul-06 0:50
Sarath C9-Jul-06 0:50 
GeneralRe: Creating a custom control? [modified] Pin
Lord Kixdemp9-Jul-06 14:12
Lord Kixdemp9-Jul-06 14:12 
QuestionHelp calling and using a functions in visual c++ 6 Pin
method0078-Jul-06 12:35
method0078-Jul-06 12:35 
QuestionProblem with 2DGraph of Nikolai Teofilov Pin
ensger8-Jul-06 8:15
ensger8-Jul-06 8:15 
AnswerRe: Problem with 2DGraph of Nikolai Teofilov Pin
Jun Du8-Jul-06 9:46
Jun Du8-Jul-06 9:46 
Questionhow to detect internet connection availability ? Pin
tns_ranjith8-Jul-06 4:20
tns_ranjith8-Jul-06 4:20 
AnswerRe: how to detect internet connection availability ? Pin
includeh108-Jul-06 6:16
includeh108-Jul-06 6:16 
AnswerRe: how to detect internet connection availability ? Pin
PJ Arends8-Jul-06 7:44
professionalPJ Arends8-Jul-06 7:44 
QuestionAvailable/installed RAM Pin
RomTibi8-Jul-06 3:10
RomTibi8-Jul-06 3:10 
AnswerRe: Available/installed RAM Pin
Gary R. Wheeler8-Jul-06 3:54
Gary R. Wheeler8-Jul-06 3:54 
GeneralRe: Available/installed RAM Pin
RomTibi8-Jul-06 5:59
RomTibi8-Jul-06 5:59 
Questionseparating strings [modified] Pin
Tara148-Jul-06 3:01
Tara148-Jul-06 3:01 

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.