Solved

Generate Alert in ASP.NET

Posted on 2003-11-05
5
332 Views
Last Modified: 2013-11-25
I want to generate alert using asp.net. Scenario is; In one stock website I found stock x is at $50. I want to get informed when the stock reaches $60.  System should send me an e-mail when it reaches to $60. I don't want a program running in a background (in schedular of windows) to do this task.
Thanks
-Ashish
0
Comment
Question by:ashishnaik1
5 Comments
 
LVL 4

Expert Comment

by:kblack15217
ID: 9688918
This can be acheived by taking advantage of the threading namespace available in .NEt.   Basically, the idea is that you spawn off a thread which has access to the parent object.   It keeps track of a property in the parent object, in this case, stock price.    In a loop, if the stock price is less than 60, it just sleeps and tries again.  But when it is above 60, you can use the parent object to invoke a callback method, which will handle your alert.

Threading is too detailed to get into on here, but here is a place to start reading.

http://www.devasp.net/net/search/default.asp?c_id=560
0
 
LVL 3

Expert Comment

by:barryfandango
ID: 9689382
Ashish,

Your criteria about background/scheduling is not clear.  There are two ways your program could run:

1. An EXE that constantly monitors the stock and sends email when some condition is reached, or
2. An EXE that checks the stock once, and that EXE is scheduled to run on a regular interval.

I'm not sure which one you're asking about.  In either case, this sort of application is probably more at home in the C# category as it is not the sort of thing you would code as an ASP.NET page.  Well: you could code it as an ASP.NET page, and keep on hitting "Refresh."
0
 
LVL 4

Expert Comment

by:kblack15217
ID: 9689423
Good point barry,
I kind of lost track of the ASP.Net part.  Threading is a solution that will work better with desktop appliations.   HOwever ASP.NET can be C#, or VB.NEt, or any other supported language.
0
 
LVL 7

Expert Comment

by:vnvk
ID: 11830640
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I will leave the following recommendation for this question in the Cleanup topic area:
    PAQ - no points refunded

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

vnvk
EE Cleanup Volunteer
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 11862964
PAQed - no points refunded (of 400)

modulo
Community Support Moderator
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now