Fast starting app

  • Thread starter Thread starter Sjaakie Helderhorst
  • Start date Start date
S

Sjaakie Helderhorst

Hi!

I use an ISDN monitor which displays caller ID. In stead of entering all
numbers manually, I wish to query a national phonenumber database, which I
obtained as a MySQL database. The only way I can pass the caller id from the
software to another app, is by executing it with a parameter (this parameter
is the phonenumber).
So far I managed to do so, I wrote a vb console app which queries the
database and writes output to a text-file which the monitor app can read.
But ... starting this little console app takes about 2,5 seconds.

Is there a smarter (and faster) way of achieving this? I can think of a
process residing in memory and is triggered by a fast starting app... can't
find any info/samples on how to achieve this.

Any help is appreciated! Thanks in advance
 
* "Sjaakie Helderhorst said:
I use an ISDN monitor which displays caller ID. In stead of entering all
numbers manually, I wish to query a national phonenumber database, which I
obtained as a MySQL database. The only way I can pass the caller id from the
software to another app, is by executing it with a parameter (this parameter
is the phonenumber).
So far I managed to do so, I wrote a vb console app which queries the
database and writes output to a text-file which the monitor app can read.
But ... starting this little console app takes about 2,5 seconds.

Is there a smarter (and faster) way of achieving this? I can think of a
process residing in memory and is triggered by a fast starting app... can't
find any info/samples on how to achieve this.

On the destination machine, you can use "ngen.exe" to generate a native
image of the application. This may decrease time needed for startup.
 
Herfried K. Wagner said:
On the destination machine, you can use "ngen.exe" to generate a native
image of the application. This may decrease time needed for startup.

I'll give it a try and let you know
Thanks!
 
Herfried K. Wagner said:
* "Sjaakie Helderhorst" <[email protected]> scripsit:
On the destination machine, you can use "ngen.exe" to generate a native
image of the application. This may decrease time needed for startup.

Unfortunately not a major increase in speed, just some milliseconds...
Is there a way of time-tracing the execution? Then I can see which step
consumes most of the time.

Another question: Would using a formless windows ap execute faster than a
console application?
 
Sjaakie said:
Unfortunately not a major increase in speed, just some milliseconds...
Is there a way of time-tracing the execution? Then I can see which step
consumes most of the time.

I thought that...
Another question: Would using a formless windows ap execute faster than a
console application?

Yes. A Windows Forms application loads a couple of DLLs, like
"System.Windows.Forms.dll" and "System.Drawing.dll", and loading DLLs
needs some time. I assume that loading the library used to establish
the connection and connecting to the database will take some time too.

Have a look if you reference libraries that are not used in your
project, and remove these references.
 
Back
Top