By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,678 Members | 1,158 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,678 IT Pros & Developers. It's quick & easy.

Application goes down with out any wornin.

P: n/a
TPI

I wrote application wich i working on IntPtr.
Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
And sometimes the application shuts down with out any wornings and
exceptions.
With out worninigs and exceptions I do not know where to look up.
I need help with this problem.

Dec 5 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
Hi,

Have you checked the event log?

Why are you using p/invoke ?

what about some tracing?, can you localize the problem, maybe write info to
a file to show the progress so you could find where the problem is.

without more info it's almost impossible to help you

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@atlantis.news.tpi.pl...

I wrote application wich i working on IntPtr.
Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
And sometimes the application shuts down with out any wornings and
exceptions.
With out worninigs and exceptions I do not know where to look up.
I need help with this problem.

Dec 5 '05 #2

P: n/a
TPI

This is recurrence object, witch i doing some calculations on first one then
is going do the secend one and to the last one then
start again. Whole project is taking IntPtr from the other aplication
(.NET).
Every thing there is recurrency even methodes call it's selef recurrency.

parent-object-child

void method(object)
{
do something;

if(object.child != null)
{
method(object.child);
}
else
{
call evend end();
}
}

This is how this works.

And I do not know how to checked the event log or do some tracing.
I've never done this before.
Would you tell me what to do?
Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:eU****************@TK2MSFTNGP11.phx.gbl...
Hi,

Have you checked the event log?

Why are you using p/invoke ?

what about some tracing?, can you localize the problem, maybe write info to a file to show the progress so you could find where the problem is.

without more info it's almost impossible to help you

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@atlantis.news.tpi.pl...

I wrote application wich i working on IntPtr.
Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
And sometimes the application shuts down with out any wornings and
exceptions.
With out worninigs and exceptions I do not know where to look up.
I need help with this problem.


Dec 6 '05 #3

P: n/a
Hi,

Are you sure all your recursive methods finish correctly? maybe you have
an infinite loop somewhere

Apart from that, d this ( if it does makes sense ) take a sample of the
data you are getting from the other app and use it internally, do not use
the external app

Did you tried to debug it?

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...

This is recurrence object, witch i doing some calculations on first one
then
is going do the secend one and to the last one then
start again. Whole project is taking IntPtr from the other aplication
(.NET).
Every thing there is recurrency even methodes call it's selef recurrency.

parent-object-child

void method(object)
{
do something;

if(object.child != null)
{
method(object.child);
}
else
{
call evend end();
}
}

This is how this works.

And I do not know how to checked the event log or do some tracing.
I've never done this before.
Would you tell me what to do?
Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:eU****************@TK2MSFTNGP11.phx.gbl...
Hi,

Have you checked the event log?

Why are you using p/invoke ?

what about some tracing?, can you localize the problem, maybe write info

to
a file to show the progress so you could find where the problem is.

without more info it's almost impossible to help you

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@atlantis.news.tpi.pl...
>
> I wrote application wich i working on IntPtr.
> Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
> And sometimes the application shuts down with out any wornings and
> exceptions.
> With out worninigs and exceptions I do not know where to look up.
> I need help with this problem.
>
>
>



Dec 6 '05 #4

P: n/a
TPI

Hi

I put in to main method try block and so far i working with out any
exceptions.
It is working slower but still working. I lost about 200 ms on one cykl.
In try block is working over a day with out any memory increment, and I
think that it's going to work.

With out that block went down sometimes after tree hours - so debugging is
impassable.
Ones I had an infinite loop, but also had an exception.

So fare is working - thaks.
Robert Janda.

Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:uJ****************@TK2MSFTNGP11.phx.gbl...
Hi,

Are you sure all your recursive methods finish correctly? maybe you have
an infinite loop somewhere

Apart from that, d this ( if it does makes sense ) take a sample of the
data you are getting from the other app and use it internally, do not use
the external app

Did you tried to debug it?

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...

This is recurrence object, witch i doing some calculations on first one
then
is going do the secend one and to the last one then
start again. Whole project is taking IntPtr from the other aplication
(.NET).
Every thing there is recurrency even methodes call it's selef recurrency.
parent-object-child

void method(object)
{
do something;

if(object.child != null)
{
method(object.child);
}
else
{
call evend end();
}
}

This is how this works.

And I do not know how to checked the event log or do some tracing.
I've never done this before.
Would you tell me what to do?
Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:eU****************@TK2MSFTNGP11.phx.gbl...
Hi,

Have you checked the event log?

Why are you using p/invoke ?

what about some tracing?, can you localize the problem, maybe write
info to
a file to show the progress so you could find where the problem is.

without more info it's almost impossible to help you

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@atlantis.news.tpi.pl...
>
> I wrote application wich i working on IntPtr.
> Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
> And sometimes the application shuts down with out any wornings and
> exceptions.
> With out worninigs and exceptions I do not know where to look up.
> I need help with this problem.
>
>
>



Dec 7 '05 #5

P: n/a
Hi ,

I bet you solve nothing, you are just catching the exception,
do this:
1- use a logger to write to the event viewer any exception you are getting
(below I send you a class you can use )
write Exception.Message and Exception.StackTrace

2- Hook AppDomain.UnhandledException and Application.ThreadException , do
the above logging

The log wrapper:
public class Logger
{
private static System.Diagnostics.EventLog eventLog1;

static public void CreateLog( string msg, EventLogEntryType level)
{
eventLog1.WriteEntry( msg, level);
}
static Logger()
{
//
// TODO: Add constructor logic here
//
eventLog1 = new System.Diagnostics.EventLog();
((System.ComponentModel.ISupportInitialize)(eventL og1)).BeginInit();
//
// eventLog1
//
eventLog1.Log = "Application";
eventLog1.Source = "LaceUP Order Dispatcher";

((System.ComponentModel.ISupportInitialize)(eventL og1)).EndInit();

}
}

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...

Hi

I put in to main method try block and so far i working with out any
exceptions.
It is working slower but still working. I lost about 200 ms on one cykl.
In try block is working over a day with out any memory increment, and I
think that it's going to work.

With out that block went down sometimes after tree hours - so debugging is
impassable.
Ones I had an infinite loop, but also had an exception.

So fare is working - thaks.
Robert Janda.

Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:uJ****************@TK2MSFTNGP11.phx.gbl...
Hi,

Are you sure all your recursive methods finish correctly? maybe you
have
an infinite loop somewhere

Apart from that, d this ( if it does makes sense ) take a sample of the
data you are getting from the other app and use it internally, do not use
the external app

Did you tried to debug it?

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...
>
> This is recurrence object, witch i doing some calculations on first one
> then
> is going do the secend one and to the last one then
> start again. Whole project is taking IntPtr from the other aplication
> (.NET).
> Every thing there is recurrency even methodes call it's selef recurrency. >
> parent-object-child
>
> void method(object)
> {
> do something;
>
> if(object.child != null)
> {
> method(object.child);
> }
> else
> {
> call evend end();
> }
> }
>
> This is how this works.
>
> And I do not know how to checked the event log or do some tracing.
> I've never done this before.
> Would you tell me what to do?
>
>
> Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
> dot.state.fl.us> napisał w wiadomości
> news:eU****************@TK2MSFTNGP11.phx.gbl...
>> Hi,
>>
>> Have you checked the event log?
>>
>> Why are you using p/invoke ?
>>
>> what about some tracing?, can you localize the problem, maybe write info > to
>> a file to show the progress so you could find where the problem is.
>>
>> without more info it's almost impossible to help you
>>
>> cheers,
>>
>> --
>> Ignacio Machin,
>> ignacio.machin AT dot.state.fl.us
>> Florida Department Of Transportation
>>
>>
>>
>> "TPI" <rt**@el.com> wrote in message
>> news:dn**********@atlantis.news.tpi.pl...
>> >
>> > I wrote application wich i working on IntPtr.
>> > Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
>> > And sometimes the application shuts down with out any wornings and
>> > exceptions.
>> > With out worninigs and exceptions I do not know where to look up.
>> > I need help with this problem.
>> >
>> >
>> >
>>
>>
>
>



Dec 7 '05 #6

P: n/a
TPI
I'll try it?
Thanks.

Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:Os****************@TK2MSFTNGP10.phx.gbl...
Hi ,

I bet you solve nothing, you are just catching the exception,
do this:
1- use a logger to write to the event viewer any exception you are getting
(below I send you a class you can use )
write Exception.Message and Exception.StackTrace

2- Hook AppDomain.UnhandledException and Application.ThreadException , do
the above logging

The log wrapper:
public class Logger
{
private static System.Diagnostics.EventLog eventLog1;

static public void CreateLog( string msg, EventLogEntryType level)
{
eventLog1.WriteEntry( msg, level);
}
static Logger()
{
//
// TODO: Add constructor logic here
//
eventLog1 = new System.Diagnostics.EventLog();
((System.ComponentModel.ISupportInitialize)(eventL og1)).BeginInit();
//
// eventLog1
//
eventLog1.Log = "Application";
eventLog1.Source = "LaceUP Order Dispatcher";

((System.ComponentModel.ISupportInitialize)(eventL og1)).EndInit();

}
}

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...

Hi

I put in to main method try block and so far i working with out any
exceptions.
It is working slower but still working. I lost about 200 ms on one cykl.
In try block is working over a day with out any memory increment, and I
think that it's going to work.

With out that block went down sometimes after tree hours - so debugging is impassable.
Ones I had an infinite loop, but also had an exception.

So fare is working - thaks.
Robert Janda.

Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
dot.state.fl.us> napisał w wiadomości
news:uJ****************@TK2MSFTNGP11.phx.gbl...
Hi,

Are you sure all your recursive methods finish correctly? maybe you
have
an infinite loop somewhere

Apart from that, d this ( if it does makes sense ) take a sample of the data you are getting from the other app and use it internally, do not use the external app

Did you tried to debug it?

cheers,

--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation
"TPI" <rt**@el.com> wrote in message
news:dn**********@nemesis.news.tpi.pl...
>
> This is recurrence object, witch i doing some calculations on first one > then
> is going do the secend one and to the last one then
> start again. Whole project is taking IntPtr from the other aplication
> (.NET).
> Every thing there is recurrency even methodes call it's selef

recurrency.
>
> parent-object-child
>
> void method(object)
> {
> do something;
>
> if(object.child != null)
> {
> method(object.child);
> }
> else
> {
> call evend end();
> }
> }
>
> This is how this works.
>
> And I do not know how to checked the event log or do some tracing.
> I've never done this before.
> Would you tell me what to do?
>
>
> Użytkownik "Ignacio Machin ( .NET/ C# MVP )" <ignacio.machin AT
> dot.state.fl.us> napisał w wiadomości
> news:eU****************@TK2MSFTNGP11.phx.gbl...
>> Hi,
>>
>> Have you checked the event log?
>>
>> Why are you using p/invoke ?
>>
>> what about some tracing?, can you localize the problem, maybe write

info
> to
>> a file to show the progress so you could find where the problem is.
>>
>> without more info it's almost impossible to help you
>>
>> cheers,
>>
>> --
>> Ignacio Machin,
>> ignacio.machin AT dot.state.fl.us
>> Florida Department Of Transportation
>>
>>
>>
>> "TPI" <rt**@el.com> wrote in message
>> news:dn**********@atlantis.news.tpi.pl...
>> >
>> > I wrote application wich i working on IntPtr.
>> > Whole thing is using Marshal.ReadInt32 and Marshal.WriteInt32.
>> > And sometimes the application shuts down with out any wornings and
>> > exceptions.
>> > With out worninigs and exceptions I do not know where to look up.
>> > I need help with this problem.
>> >
>> >
>> >
>>
>>
>
>



Dec 8 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.