Showing posts with label app. Show all posts
Showing posts with label app. Show all posts

Saturday, March 31, 2012

Things different in Whidbey??

Hi,
I think I really need help. New job, and I'm supposed to show a "simple asp.net app" tomorrow and don't know what to do.

Come from vb.net, and just learned some C#, and some asp.net (using IIS and notepad)

I got vs 2003 on this machine, and can easily create new asp.net web app, then I get a form and all that and can carry on.

but seems to be completely different at work where they use whidbey, but then you got nothing in your solution?

Useless to ask at work, as no one understand my accent and I dont' speak thir language!!!

Pls. If someone really wanna help, tell me what to do, and also give me simple stupid page or two, just to show tomorrow and keep them quite. I plan to work the whole week-end to figure things out...PLEEEEEAAASEGo to www.w3schools.com and pick one example...

http://www.w3schools.com/aspnet/aspnet_examples.asp

http://www.w3schools.com/aspnet/showasp.asp?filename=demo_pageispostback

http://www.w3schools.com/aspnet/showasp.asp?filename=demo_dbconn_datalist
Useless to ask at work, as no one understand my accent and I dont' speak thir language!!!

That's not a good attitude.

Why not get VS Beta 1 or 2 and then try it out yourself? It's pretty much the same method as in VS 2003.

Wednesday, March 28, 2012

Things different in Whidbey??

Hi,
I think I really need help. New job, and I'm supposed to show a "simple asp.net app" tomorrow and don't know what to do.

Come from vb.net, and just learned some C#, and some asp.net (using IIS and notepad)

I got vs 2003 on this machine, and can easily create new asp.net web app, then I get a form and all that and can carry on.

but seems to be completely different at work where they use whidbey, but then you got nothing in your solution?

Useless to ask at work, as no one understand my accent and I dont' speak thir language!!!

Pls. If someone really wanna help, tell me what to do, and also give me simple stupid page or two, just to show tomorrow and keep them quite. I plan to work the whole week-end to figure things out...PLEEEEEAAASEGo to www.w3schools.com and pick one example...

http://www.w3schools.com/aspnet/aspnet_examples.asp

http://www.w3schools.com/aspnet/showasp.asp?filename=demo_pageispostback

http://www.w3schools.com/aspnet/showasp.asp?filename=demo_dbconn_datalist
Useless to ask at work, as no one understand my accent and I dont' speak thir language!!!

That's not a good attitude.

Why not get VS Beta 1 or 2 and then try it out yourself? It's pretty much the same method as in VS 2003.

Third party cookies and P3P

Does anyone have any documentation on compact privacy policy
and asp.net session or http session cookies.

I have a third party app that relies on a session cookie to maintain
the state of my app in a users site.

Currently my P3P policy is causing IE6 to reject my third party session
cookie.

I have my P3P working and do not collect personal info, add headers
including my
P3P info as the per documentation I have found so far.

Is there anything else I can do from asp.net to get my third party session
accepted
in IE6 ?

Chris LangI am having the same problem. The default configuration of Internet
Explorer seems to block all third party cookies, even if they are just
for state information. I can't figure out what I can do with my p3p
policy settings to get around this. Does anyone know how?

I'm trying to make it so that my site can be embedded inside other sites
using frames. When a code is attached to the url to my site, then my
own header and footer banners get turned off. I use a cookie so track
that the site is embedded, that way I don't have to update all the
hyperlinks on the entire site dynamically to maintain state information.

Thanks anyone for help.

Meet people for friendship, contacts,
or romance using free instant messaging software! See a picture you
like? Click once for a private conversation with that person!

www.SEN.us

*** Sent via Developersdex http://www.developersdex.com ***

Third-party BLOG app to use in ASP.NET website?

I want to have a BLOG in my ASP.NET website. Are there third-party
apps/plug-ins already out there? If so, can someone recommend the top few
for .NET? Is there an app from Microsoft more specific/integrated with an
ASP.NET app?

Thanks very much,
RonCheck these out :

http://csharp-source.net/open-source/bloggers|

You might also want to check out Presstopia :
http://presstopia.com/dnn/Default.aspx?tabid=159
...and Community Server :
http://communityserver.org/content/...yServerNow.aspx
Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en espaol : http://asp.net.do/foros/
===================================
"Ronald S. Cook" <rcook@.westinis.comwrote in message
news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...

Quote:

Originally Posted by

>I want to have a BLOG in my ASP.NET website. Are there third-party apps/plug-ins already out
>there? If so, can someone recommend the top few for .NET? Is there an app from Microsoft more
>specific/integrated with an ASP.NET app?
>
Thanks very much,
Ron
>


I use thinkjot on my site

No database to worry about, and quite easy to setup
http://www.process64.com/thinkjot/download.htm
Regards

John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
"Juan T. Llibre" <nomailreplies@.nowhere.comwrote in message
news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...

Quote:

Originally Posted by

Check these out :
>
http://csharp-source.net/open-source/bloggers|
>
You might also want to check out Presstopia :
http://presstopia.com/dnn/Default.aspx?tabid=159
>
...and Community Server :
http://communityserver.org/content/...yServerNow.aspx
>
>
>
>
Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en espaol : http://asp.net.do/foros/
===================================
"Ronald S. Cook" <rcook@.westinis.comwrote in message
news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...

Quote:

Originally Posted by

>>I want to have a BLOG in my ASP.NET website. Are there third-party
>>apps/plug-ins already out there? If so, can someone recommend the top few
>>for .NET? Is there an app from Microsoft more specific/integrated with an
>>ASP.NET app?
>>
>Thanks very much,
>Ron
>>


>
>


dasBlog

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
"John Timney (MVP)" <x_john@.timney.eclipse.co.ukwrote in message
news:osidnRnwl7RMPwbYnZ2dnUVZ8sGvnZ2d@.eclipse.net. uk...

Quote:

Originally Posted by

>I use thinkjot on my site
>
No database to worry about, and quite easy to setup
http://www.process64.com/thinkjot/download.htm
>
Regards
>
John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
>
>
"Juan T. Llibre" <nomailreplies@.nowhere.comwrote in message
news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...

Quote:

Originally Posted by

>Check these out :
>>
>http://csharp-source.net/open-source/bloggers|
>>
>You might also want to check out Presstopia :
>http://presstopia.com/dnn/Default.aspx?tabid=159
>>
>...and Community Server :
>http://communityserver.org/content/...yServerNow.aspx
>>
>>
>>
>>
>Juan T. Llibre, asp.net MVP
>asp.net faq : http://asp.net.do/faq/
>foros de asp.net, en espaol : http://asp.net.do/foros/
>===================================
>"Ronald S. Cook" <rcook@.westinis.comwrote in message
>news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...

Quote:

Originally Posted by

>>>I want to have a BLOG in my ASP.NET website. Are there third-party
>>>apps/plug-ins already out there? If so, can someone recommend the top
>>>few for .NET? Is there an app from Microsoft more specific/integrated
>>>with an ASP.NET app?
>>>
>>Thanks very much,
>>Ron
>>>


>>
>>


>
>


Thinkjot is just the dasblog code cut down

--
--
Regards

John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
"clintonG" <csgallagher@.REMOVETHISTEXTmetromilwaukee.comwrote in message
news:uRhP9G1LHHA.4000@.TK2MSFTNGP06.phx.gbl...

Quote:

Originally Posted by

dasBlog
>
<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
>
"John Timney (MVP)" <x_john@.timney.eclipse.co.ukwrote in message
news:osidnRnwl7RMPwbYnZ2dnUVZ8sGvnZ2d@.eclipse.net. uk...

Quote:

Originally Posted by

>>I use thinkjot on my site
>>
>No database to worry about, and quite easy to setup
>http://www.process64.com/thinkjot/download.htm
>>
>Regards
>>
>John Timney (MVP)
>VISIT MY WEBSITE:
>http://www.johntimney.com
>http://www.johntimney.com/blog
>>
>>
>"Juan T. Llibre" <nomailreplies@.nowhere.comwrote in message
>news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...

Quote:

Originally Posted by

>>Check these out :
>>>
>>http://csharp-source.net/open-source/bloggers|
>>>
>>You might also want to check out Presstopia :
>>http://presstopia.com/dnn/Default.aspx?tabid=159
>>>
>>...and Community Server :
>>http://communityserver.org/content/...yServerNow.aspx
>>>
>>>
>>>
>>>
>>Juan T. Llibre, asp.net MVP
>>asp.net faq : http://asp.net.do/faq/
>>foros de asp.net, en espaol : http://asp.net.do/foros/
>>===================================
>>"Ronald S. Cook" <rcook@.westinis.comwrote in message
>>news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...
>>>>I want to have a BLOG in my ASP.NET website. Are there third-party
>>>>apps/plug-ins already out there? If so, can someone recommend the top
>>>>few for .NET? Is there an app from Microsoft more specific/integrated
>>>>with an ASP.NET app?
>>>>
>>>Thanks very much,
>>>Ron
>>>>
>>>
>>>


>>
>>


>
>


Nice of you to point that out. Visiting the ThinkJot page inferred an
orphaned initiative and AFIK dasBlog continues to be developed by what's his
name [1]. The point is, the objective many have on their minds is how to
integrate blogging functionality into an existing site.

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
[1] Scott Hanselman
http://www.hanselman.com/blog/Categ...=DasBlog&page=2
"John Timney (MVP)" <x_john@.timney.eclipse.co.ukwrote in message
news:T4KdnW7UQPOHlwHYRVnyvgA@.eclipse.net.uk...

Quote:

Originally Posted by

Thinkjot is just the dasblog code cut down
>
--
--
Regards
>
John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
>
>
"clintonG" <csgallagher@.REMOVETHISTEXTmetromilwaukee.comwrote in message
news:uRhP9G1LHHA.4000@.TK2MSFTNGP06.phx.gbl...

Quote:

Originally Posted by

>dasBlog
>>
><%= Clinton Gallagher
> NET csgallagher AT metromilwaukee.com
> URL http://clintongallagher.metromilwaukee.com/
> MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
>>
>"John Timney (MVP)" <x_john@.timney.eclipse.co.ukwrote in message
>news:osidnRnwl7RMPwbYnZ2dnUVZ8sGvnZ2d@.eclipse.net. uk...

Quote:

Originally Posted by

>>>I use thinkjot on my site
>>>
>>No database to worry about, and quite easy to setup
>>http://www.process64.com/thinkjot/download.htm
>>>
>>Regards
>>>
>>John Timney (MVP)
>>VISIT MY WEBSITE:
>>http://www.johntimney.com
>>http://www.johntimney.com/blog
>>>
>>>
>>"Juan T. Llibre" <nomailreplies@.nowhere.comwrote in message
>>news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...
>>>Check these out :
>>>>
>>>http://csharp-source.net/open-source/bloggers|
>>>>
>>>You might also want to check out Presstopia :
>>>http://presstopia.com/dnn/Default.aspx?tabid=159
>>>>
>>>...and Community Server :
>>>http://communityserver.org/content/...yServerNow.aspx
>>>>
>>>>
>>>>
>>>>
>>>Juan T. Llibre, asp.net MVP
>>>asp.net faq : http://asp.net.do/faq/
>>>foros de asp.net, en espaol : http://asp.net.do/foros/
>>>===================================
>>>"Ronald S. Cook" <rcook@.westinis.comwrote in message
>>>news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...
>>>>>I want to have a BLOG in my ASP.NET website. Are there third-party
>>>>>apps/plug-ins already out there? If so, can someone recommend the top
>>>>>few for .NET? Is there an app from Microsoft more specific/integrated
>>>>>with an ASP.NET app?
>>>>>
>>>>Thanks very much,
>>>>Ron
>>>>>
>>>>
>>>>
>>>
>>>


>>
>>


>
>

Third-party BLOG app to use in ASP.NET website?

I want to have a BLOG in my ASP.NET website. Are there third-party
apps/plug-ins already out there? If so, can someone recommend the top few
for .NET? Is there an app from Microsoft more specific/integrated with an
ASP.NET app?
Thanks very much,
RonCheck these out :
http://csharp-source.net/open-source/bloggers|
You might also want to check out Presstopia :
http://presstopia.com/dnn/Default.aspx?tabid=159
...and Community Server :
http://communityserver.org/content/...yServerNow.aspx
Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en espaol : http://asp.net.do/foros/
===================================
"Ronald S. Cook" <rcook@.westinis.com> wrote in message
news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...
>I want to have a BLOG in my ASP.NET website. Are there third-party apps/pl
ug-ins already out
>there? If so, can someone recommend the top few for .NET? Is there an app
from Microsoft more
>specific/integrated with an ASP.NET app?
> Thanks very much,
> Ron
>
I use thinkjot on my site
No database to worry about, and quite easy to setup
http://www.process64.com/thinkjot/download.htm
Regards
John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
"Juan T. Llibre" <nomailreplies@.nowhere.com> wrote in message
news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...
> Check these out :
> http://csharp-source.net/open-source/bloggers|
> You might also want to check out Presstopia :
> http://presstopia.com/dnn/Default.aspx?tabid=159
> ...and Community Server :
> http://communityserver.org/content/...yServerNow.aspx
>
>
> Juan T. Llibre, asp.net MVP
> asp.net faq : http://asp.net.do/faq/
> foros de asp.net, en espaol : http://asp.net.do/foros/
> ===================================
> "Ronald S. Cook" <rcook@.westinis.com> wrote in message
> news:6FF5EAD4-8592-444A-BEA7-10C058734CD6@.microsoft.com...
>
dasBlog
<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
"John Timney (MVP)" <x_john@.timney.eclipse.co.uk> wrote in message
news:osidnRnwl7RMPwbYnZ2dnUVZ8sGvnZ2d@.ec
lipse.net.uk...
>I use thinkjot on my site
> No database to worry about, and quite easy to setup
> http://www.process64.com/thinkjot/download.htm
> Regards
> John Timney (MVP)
> VISIT MY WEBSITE:
> http://www.johntimney.com
> http://www.johntimney.com/blog
>
> "Juan T. Llibre" <nomailreplies@.nowhere.com> wrote in message
> news:uRAWhYsLHHA.1248@.TK2MSFTNGP02.phx.gbl...
>
Thinkjot is just the dasblog code cut down
--
Regards
John Timney (MVP)
VISIT MY WEBSITE:
http://www.johntimney.com
http://www.johntimney.com/blog
"clintonG" < csgallagher@.REMOVETHISTEXTmetromilwaukee
.com> wrote in message
news:uRhP9G1LHHA.4000@.TK2MSFTNGP06.phx.gbl...
> dasBlog
> <%= Clinton Gallagher
> NET csgallagher AT metromilwaukee.com
> URL http://clintongallagher.metromilwaukee.com/
> MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
> "John Timney (MVP)" <x_john@.timney.eclipse.co.uk> wrote in message
> news:osidnRnwl7RMPwbYnZ2dnUVZ8sGvnZ2d@.ec
lipse.net.uk...
>
Nice of you to point that out. Visiting the ThinkJot page inferred an
orphaned initiative and AFIK dasBlog continues to be developed by what's his
name [1]. The point is, the objective many have on their minds is how to
integrate blogging functionality into an existing site.
<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=...38&z=17&l=0&m=h
[1] Scott Hanselman
http://www.hanselman.com/blog/Categ...=DasBlog&page=2
"John Timney (MVP)" <x_john@.timney.eclipse.co.uk> wrote in message
news:T4KdnW7UQPOHlwHYRVnyvgA@.eclipse.net.uk...
> Thinkjot is just the dasblog code cut down
> --
> --
> Regards
> John Timney (MVP)
> VISIT MY WEBSITE:
> http://www.johntimney.com
> http://www.johntimney.com/blog
>
> "clintonG" < csgallagher@.REMOVETHISTEXTmetromilwaukee
.com> wrote in message
> news:uRhP9G1LHHA.4000@.TK2MSFTNGP06.phx.gbl...
>

Saturday, March 24, 2012

Thought about server controls

Hi all, I'm new to web app development and jumped right into ASP.NET - so of course I created an application full of asp:xxxxx controls with runat=server. Now I wonder if this is really not the recommended practice? Are there times that a plain old input box or drop down list would do better? Any advice would be appreciated! Thanks!Hello,

there are a few differences between these two kind of controls. In the following i just describe what i´m actually remember but maybe there are a bit it more...

First of all i give you a link where you can read the differences in detail:Introduction to ASP.NET Server Controls

Second is here a short summary:

1. Browser Compatibility
The HTML Server Controls have no mechanism of identifying the capabilities of the client browser accessing the current page.

ASP .NET Server Controls can however detect the target browser's capabilities and render themselves accordingly.

2. Object Model
The HTML Server Controls follow the HTML-centric object model.

ASP .NET Server Controls have an object model different from the traditional HTML and even provide a set of properties and methods that can change the outlook and behavior of the controls.

Sometimes i have heart that ASP.Net controls are a little bit more slowly than the appropriate html controls but i haven't experienced this by now...

Regards,
Ok, so you haven't experienced slower pages with server controls than a HTML control? I guess that is my main concern, I just want to make sure I am not wasting processor time with server controls when I may not really need them.
There is an overload. All the extra property and method of the asp.net version of the standard HTML need to be stored somewhere, as in the server memory.

While you may not experience slowdown, using them only when you need the extra fonctionality is the way to go IMHO.

What too much of them is will be up to you to decide though.
Thank you soo much!

Thursday, March 22, 2012

Thread abort error - REVISITED

I'm periodically getting "Thread Abort Error" errors thown from my web
app. My app will throw like 5 of these and will work normally again.
I'm thinking it is because my worker process was recycling so it
aborted all the threads. My question is, How can I stop it?Don't put any code after Response.Redirect(). That's it. Those Thread
Abort Exceptions will go away.

If you have so much as a return statement after a
Response.Redirect(?,true);, you'll run the risk of seeing these
exceptions. Regardless of what you do, you shouldn't be sweating them.
They're completely harmless.

Jason Kester
Expat Software Consulting Services
http://www.expatsoftware.com/

--
Get your own Travel Blog, with itinerary maps and photos!
http://www.blogabond.com/

Thread abort error - REVISITED

I'm periodically getting "Thread Abort Error" errors thown from my web
app. My app will throw like 5 of these and will work normally again.
I'm thinking it is because my worker process was recycling so it
aborted all the threads. My question is, How can I stop it?Don't put any code after Response.Redirect(). That's it. Those Thread
Abort Exceptions will go away.
If you have so much as a return statement after a
Response.Redirect(?,true);, you'll run the risk of seeing these
exceptions. Regardless of what you do, you shouldn't be sweating them.
They're completely harmless.
Jason Kester
Expat Software Consulting Services
http://www.expatsoftware.com/
Get your own Travel Blog, with itinerary maps and photos!
http://www.blogabond.com/

Thread doesnt do anything

I have a Sub called SendMessages() that is supposed to do some database work and send an email message in my web app.

Now if I call it directly, it does what it should. I've now been trying to place this Sub into a thread of its own..

i.e

Dim sendMessageThread as New Thread(AddressOf SendMessages)
sendMessageThread.Start()

But the page ends up doing nothing...

Any ideas?Is your SendMessages sub within the same class or in another class?
Have you stepped through your code to see if the thread is entering the sub?
It is in the same class. I'm not using VS.NET so I can't do any stepping...

The thread is being called from Page_Load()
Post the code.
As far as it seems, the Sub ReceiveMessages is not being called at all!!!
Here is my code

Sub Page_Load()
Dim NewThread As Thread = New Thread(AddressOf ReceiveMessages)

NewThread.Priority = ThreadPriority.Lowest
NewThread.Start()
End Sub

Public Sub ReceiveMessages()
' Code here to connect to pop3 server and loop through messages
End Sub

Thread object vs Threadpool?

Hi all!
In my webb app I'm about to introduce a way of processing long running tasks
in the background.
As the long running task gathers data from a database process them and
compile them into a file appx 80 mbytes large it is a resource demanding
task both of the CPU and the memory.
So I think I should restrict how many of these tasks that should be able to
start and make them run in the background.
First I read about the Thread class and thougth: Fine I'll use a thread and
then I'll write a utility class that will queue the tasks and make them run
either one after one or not too many at a time.
I'd set threads' priority to belowNormal or lowest.
Then I discovered the threadpool class and thought: Hey here's the queuing
abillity I was looking for. But then I found no way of setting the priority
of the thread that would start the long running task and I don't want to
make the web pages serve slowly.
Does anyone have any advice on whether I should use the threadpool or create
thread objects "on my own" in the code?
Thanks in advance!
mortbThreadPool class is mostly used for fire and forget tasks.
Use Thread class if extended control is needed.
-
Milosz Skalecki
MCP, MCAD
"mortb" wrote:

> Hi all!
> In my webb app I'm about to introduce a way of processing long running tas
ks
> in the background.
> As the long running task gathers data from a database process them and
> compile them into a file appx 80 mbytes large it is a resource demanding
> task both of the CPU and the memory.
> So I think I should restrict how many of these tasks that should be able t
o
> start and make them run in the background.
> First I read about the Thread class and thougth: Fine I'll use a thread an
d
> then I'll write a utility class that will queue the tasks and make them ru
n
> either one after one or not too many at a time.
> I'd set threads' priority to belowNormal or lowest.
> Then I discovered the threadpool class and thought: Hey here's the queuing
> abillity I was looking for. But then I found no way of setting the priorit
y
> of the thread that would start the long running task and I don't want to
> make the web pages serve slowly.
> Does anyone have any advice on whether I should use the threadpool or crea
te
> thread objects "on my own" in the code?
> Thanks in advance!
> mortb
>
>

Tuesday, March 13, 2012

Thread object vs Threadpool?

Hi all!

In my webb app I'm about to introduce a way of processing long running tasks
in the background.
As the long running task gathers data from a database process them and
compile them into a file appx 80 mbytes large it is a resource demanding
task both of the CPU and the memory.
So I think I should restrict how many of these tasks that should be able to
start and make them run in the background.

First I read about the Thread class and thougth: Fine I'll use a thread and
then I'll write a utility class that will queue the tasks and make them run
either one after one or not too many at a time.
I'd set threads' priority to belowNormal or lowest.

Then I discovered the threadpool class and thought: Hey here's the queuing
abillity I was looking for. But then I found no way of setting the priority
of the thread that would start the long running task and I don't want to
make the web pages serve slowly.

Does anyone have any advice on whether I should use the threadpool or create
thread objects "on my own" in the code?

Thanks in advance!
mortbThreadPool class is mostly used for fire and forget tasks.
Use Thread class if extended control is needed.
-
Milosz Skalecki
MCP, MCAD

"mortb" wrote:

> Hi all!
> In my webb app I'm about to introduce a way of processing long running tasks
> in the background.
> As the long running task gathers data from a database process them and
> compile them into a file appx 80 mbytes large it is a resource demanding
> task both of the CPU and the memory.
> So I think I should restrict how many of these tasks that should be able to
> start and make them run in the background.
> First I read about the Thread class and thougth: Fine I'll use a thread and
> then I'll write a utility class that will queue the tasks and make them run
> either one after one or not too many at a time.
> I'd set threads' priority to belowNormal or lowest.
> Then I discovered the threadpool class and thought: Hey here's the queuing
> abillity I was looking for. But then I found no way of setting the priority
> of the thread that would start the long running task and I don't want to
> make the web pages serve slowly.
> Does anyone have any advice on whether I should use the threadpool or create
> thread objects "on my own" in the code?
> Thanks in advance!
> mortb
>

thread safety

Hi,
I have a web app which has the following design to get to the DB
Web Page (uses)
-> .net DLL library
--> has a class with static methods
--> static method to-do basic DB operations like create a
DataReader for given sql, get Dataset etc
Big question is... Is this design safe when a lot of users are hitting the
web site from the asp.net threading perspective?As long as the static methods dont access static fields or properties then i
t
should be thread safe.
Ciaran O''Donnell
http://wannabedeveloper.space.live.com
"tjain" wrote:

> Hi,
> I have a web app which has the following design to get to the DB
> Web Page (uses)
> -> .net DLL library
> --> has a class with static methods
> --> static method to-do basic DB operations like create a
> DataReader for given sql, get Dataset etc
> Big question is... Is this design safe when a lot of users are hitting th
e
> web site from the asp.net threading perspective?
>

Thread was being aborted

Howdy,
I have an error mod in my app that emails me whenever there is an error. I
use try..catch to capture the error. It works great, I love it, except for
this one minor issue. Whenever there is a script that processes some data
then issues a response.redirect() I get "Thread was being aborted" emailed
to me. Below is an example of a script of where the error is occuring. It
doesn't affect the end user at all, but I just keep getting the emails and
I'm going live with this today, which means more emails :(
Try
sqlconn.Open()
If sqlcomm.ExecuteNonQuery > 0 Then
lblError.Text = ""
sqlconn.Close()
Response.Redirect("eventhotels.aspx?EID=" & EID)
Else
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
"nothing to update.")
End If
Catch ex As Exception
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
ex.Message)
End Try
I tried putting the sqlconn.close into the finally statement but still for
the same results.
Thanks!!
David Lozzi
Web Applications Developer
dlozzi@dotnet.itags.org.(remove-this)delphi-ts.comCatch the ThreadAbortException
Catch tae as System.Threading.ThreadAbortException
' ignore it.
Catch ex as Exception
' email the error
End Try
"David Lozzi" <DavidLozzi@.nospam.nospam> wrote in message
news:eTyw4PSHGHA.1032@.TK2MSFTNGP11.phx.gbl...
> Howdy,
> I have an error mod in my app that emails me whenever there is an error. I
> use try..catch to capture the error. It works great, I love it, except for
> this one minor issue. Whenever there is a script that processes some data
> then issues a response.redirect() I get "Thread was being aborted" emailed
> to me. Below is an example of a script of where the error is occuring. It
> doesn't affect the end user at all, but I just keep getting the emails and
> I'm going live with this today, which means more emails :(
> Try
> sqlconn.Open()
> If sqlcomm.ExecuteNonQuery > 0 Then
> lblError.Text = ""
> sqlconn.Close()
> Response.Redirect("eventhotels.aspx?EID=" & EID)
> Else
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> "nothing to update.")
> End If
> Catch ex As Exception
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> ex.Message)
> End Try
> I tried putting the sqlconn.close into the finally statement but still for
> the same results.
> Thanks!!
> --
> David Lozzi
> Web Applications Developer
> dlozzi@.(remove-this)delphi-ts.com
>
>
You can prevent this exception from being thrown by using the
overloaded version of Response.Redirect and passing False into the 2nd
parameter.
You are getting this exception because the Response.Redirect method
internally calls Response.End,which raises this exception and the page
processing terminates. Response.End raises the exception indirectly through
calling Thread.Abort. Move the redirect to outside of the Try block, and use
the "false" overload of Response.Redirect method:
Instead of putting Response.Redirect into a Try..Catch block. You may try
this one:
Dim redirect as Boolean =False;
Try
sqlconn.Open()
If sqlcomm.ExecuteNonQuery > 0 Then
lblError.Text = ""
sqlconn.Close()
Else
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
"nothing to update.")
End If
Catch ex As Exception
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
ex.Message)
End Try
If Redirect Then Response.Redirect("eventhotels.aspx?EID=" & EID, False)
--Peter
--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com
"David Lozzi" wrote:

> Howdy,
> I have an error mod in my app that emails me whenever there is an error. I
> use try..catch to capture the error. It works great, I love it, except for
> this one minor issue. Whenever there is a script that processes some data
> then issues a response.redirect() I get "Thread was being aborted" emailed
> to me. Below is an example of a script of where the error is occuring. It
> doesn't affect the end user at all, but I just keep getting the emails and
> I'm going live with this today, which means more emails :(
> Try
> sqlconn.Open()
> If sqlcomm.ExecuteNonQuery > 0 Then
> lblError.Text = ""
> sqlconn.Close()
> Response.Redirect("eventhotels.aspx?EID=" & EID)
> Else
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> "nothing to update.")
> End If
> Catch ex As Exception
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> ex.Message)
> End Try
> I tried putting the sqlconn.close into the finally statement but still for
> the same results.
> Thanks!!
> --
> David Lozzi
> Web Applications Developer
> dlozzi@.(remove-this)delphi-ts.com
>
>
>

Thread was being aborted

Howdy,

I have an error mod in my app that emails me whenever there is an error. I
use try..catch to capture the error. It works great, I love it, except for
this one minor issue. Whenever there is a script that processes some data
then issues a response.redirect() I get "Thread was being aborted" emailed
to me. Below is an example of a script of where the error is occuring. It
doesn't affect the end user at all, but I just keep getting the emails and
I'm going live with this today, which means more emails :(

Try
sqlconn.Open()
If sqlcomm.ExecuteNonQuery > 0 Then
lblError.Text = ""
sqlconn.Close()
Response.Redirect("eventhotels.aspx?EID=" & EID)
Else
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
"nothing to update.")
End If
Catch ex As Exception
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
ex.Message)
End Try

I tried putting the sqlconn.close into the finally statement but still for
the same results.

Thanks!!

--
David Lozzi
Web Applications Developer
dlozzi@dotnet.itags.org.(remove-this)delphi-ts.comCatch the ThreadAbortException

Catch tae as System.Threading.ThreadAbortException
' ignore it.
Catch ex as Exception
' email the error
End Try

"David Lozzi" <DavidLozzi@.nospam.nospam> wrote in message
news:eTyw4PSHGHA.1032@.TK2MSFTNGP11.phx.gbl...
> Howdy,
> I have an error mod in my app that emails me whenever there is an error. I
> use try..catch to capture the error. It works great, I love it, except for
> this one minor issue. Whenever there is a script that processes some data
> then issues a response.redirect() I get "Thread was being aborted" emailed
> to me. Below is an example of a script of where the error is occuring. It
> doesn't affect the end user at all, but I just keep getting the emails and
> I'm going live with this today, which means more emails :(
> Try
> sqlconn.Open()
> If sqlcomm.ExecuteNonQuery > 0 Then
> lblError.Text = ""
> sqlconn.Close()
> Response.Redirect("eventhotels.aspx?EID=" & EID)
> Else
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> "nothing to update.")
> End If
> Catch ex As Exception
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> ex.Message)
> End Try
> I tried putting the sqlconn.close into the finally statement but still for
> the same results.
> Thanks!!
> --
> David Lozzi
> Web Applications Developer
> dlozzi@.(remove-this)delphi-ts.com
>
You can prevent this exception from being thrown by using the
overloaded version of Response.Redirect and passing False into the 2nd
parameter.
You are getting this exception because the Response.Redirect method
internally calls Response.End,which raises this exception and the page
processing terminates. Response.End raises the exception indirectly through
calling Thread.Abort. Move the redirect to outside of the Try block, and use
the "false" overload of Response.Redirect method:

Instead of putting Response.Redirect into a Try..Catch block. You may try
this one:

Dim redirect as Boolean =False;
Try
sqlconn.Open()
If sqlcomm.ExecuteNonQuery > 0 Then
lblError.Text = ""
sqlconn.Close()

Else
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
"nothing to update.")
End If
Catch ex As Exception
sqlconn.Close()
lblError.Text = EmailError("eventhoteladd", "savehotel",
ex.Message)
End Try
If Redirect Then Response.Redirect("eventhotels.aspx?EID=" & EID, False)

--Peter
--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com

"David Lozzi" wrote:

> Howdy,
> I have an error mod in my app that emails me whenever there is an error. I
> use try..catch to capture the error. It works great, I love it, except for
> this one minor issue. Whenever there is a script that processes some data
> then issues a response.redirect() I get "Thread was being aborted" emailed
> to me. Below is an example of a script of where the error is occuring. It
> doesn't affect the end user at all, but I just keep getting the emails and
> I'm going live with this today, which means more emails :(
> Try
> sqlconn.Open()
> If sqlcomm.ExecuteNonQuery > 0 Then
> lblError.Text = ""
> sqlconn.Close()
> Response.Redirect("eventhotels.aspx?EID=" & EID)
> Else
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> "nothing to update.")
> End If
> Catch ex As Exception
> sqlconn.Close()
> lblError.Text = EmailError("eventhoteladd", "savehotel",
> ex.Message)
> End Try
> I tried putting the sqlconn.close into the finally statement but still for
> the same results.
> Thanks!!
> --
> David Lozzi
> Web Applications Developer
> dlozzi@.(remove-this)delphi-ts.com
>
>

Thread was being aborted errors

Hi,
I have an asp.net web app that is intermittently throwing "Thread was being
aborted." errors in my data access component. This seems to occur when the
app is under a heavier than normal load. I don't get any of these errors for
days, then I get a bunch all at once.
I would have thought if the database call was timing out I would get a
timeout
error.
The server is Win 2003 (under VMware), and hosts multiple asp and asp.net
web applications.

This is a sample of the exception details I'm getting:

System.Threading.ThreadAbortException: Thread was being aborted.
at System.Data.SqlClient.SqlCommand.ExecuteReader(Com mandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
at System.Data.SqlClient.SqlCommand.ExecuteReader(Com mandBehavior behavior)
at
System.Data.SqlClient.SqlCommand.System.Data.IDbCo mmand.ExecuteReader(CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
at NCSUtilities.DataAccess.ExecuteDataset(SqlConnecti on connection,
CommandType commandType, String commandText, SqlParameter[] commandParameters)
at NCSUtilities.DataAccess.ExecuteDataset(String connectionString,
CommandType commandType, String commandText, SqlParameter[] commandParameters)

I got a suggestion to look at the "DefaultAppPool" properties on the web
server, but I'm not sure what settings to modify.

Any ideas on how I could identify the cause or how I could resolve this
would be greatly appreciated.

Thanks,
Keith FIn most circumstances that I have seen, this issue occurs when the
application pool is being reset. One easy way to isolate the problem is to
match the times of the thread error with the application pool reset log in
the windows event viewer. The fix is to increase the recycle parameters on
the applicaiton pool in question.

--
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"Keith F." <KeithF@.discussions.microsoft.com> wrote in message
news:D42B570D-11E4-485A-8CA9-B55D3D31A389@.microsoft.com...
> Hi,
> I have an asp.net web app that is intermittently throwing "Thread was
> being
> aborted." errors in my data access component. This seems to occur when the
> app is under a heavier than normal load. I don't get any of these errors
> for
> days, then I get a bunch all at once.
> I would have thought if the database call was timing out I would get a
> timeout
> error.
> The server is Win 2003 (under VMware), and hosts multiple asp and asp.net
> web applications.
> This is a sample of the exception details I'm getting:
> System.Threading.ThreadAbortException: Thread was being aborted.
> at System.Data.SqlClient.SqlCommand.ExecuteReader(Com mandBehavior
> cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
> at System.Data.SqlClient.SqlCommand.ExecuteReader(Com mandBehavior
> behavior)
> at
> System.Data.SqlClient.SqlCommand.System.Data.IDbCo mmand.ExecuteReader(CommandBehavior
> behavior)
> at System.Data.Common.DbDataAdapter.FillFromCommand(O bject data, Int32
> startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> CommandBehavior behavior)
> at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
> startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> CommandBehavior behavior)
> at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
> at NCSUtilities.DataAccess.ExecuteDataset(SqlConnecti on connection,
> CommandType commandType, String commandText, SqlParameter[]
> commandParameters)
> at NCSUtilities.DataAccess.ExecuteDataset(String connectionString,
> CommandType commandType, String commandText, SqlParameter[]
> commandParameters)
> I got a suggestion to look at the "DefaultAppPool" properties on the web
> server, but I'm not sure what settings to modify.
> Any ideas on how I could identify the cause or how I could resolve this
> would be greatly appreciated.
> Thanks,
> Keith F

Thread was being aborted errors

Hi,
I have an asp.net web app that is intermittently throwing "Thread was being
aborted." errors in my data access component. This seems to occur when the
app is under a heavier than normal load. I don't get any of these errors for
days, then I get a bunch all at once.
I would have thought if the database call was timing out I would get a
timeout
error.
The server is Win 2003 (under VMware), and hosts multiple asp and asp.net
web applications.
This is a sample of the exception details I'm getting:
System.Threading.ThreadAbortException: Thread was being aborted.
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior)
at
System.Data.SqlClient.SqlCommand.System.Data.IDbCommand.ExecuteReader(Comman
dBehavior behavior)
at System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
at NCSUtilities.DataAccess.ExecuteDataset(SqlConnection connection,
CommandType commandType, String commandText, SqlParameter[] commandParameter
s)
at NCSUtilities.DataAccess.ExecuteDataset(String connectionString,
CommandType commandType, String commandText, SqlParameter[] commandParameter
s)
I got a suggestion to look at the "DefaultAppPool" properties on the web
server, but I'm not sure what settings to modify.
Any ideas on how I could identify the cause or how I could resolve this
would be greatly appreciated.
Thanks,
Keith FIn most circumstances that I have seen, this issue occurs when the
application pool is being reset. One easy way to isolate the problem is to
match the times of the thread error with the application pool reset log in
the windows event viewer. The fix is to increase the recycle parameters on
the applicaiton pool in question.
Regards,
Alvin Bruney
[ASP.NET MVP http://mvp.support.microsoft.com/default.aspx]
Got tidbits? Get it here... http://tinyurl.com/27cok
"Keith F." <KeithF@.discussions.microsoft.com> wrote in message
news:D42B570D-11E4-485A-8CA9-B55D3D31A389@.microsoft.com...
> Hi,
> I have an asp.net web app that is intermittently throwing "Thread was
> being
> aborted." errors in my data access component. This seems to occur when the
> app is under a heavier than normal load. I don't get any of these errors
> for
> days, then I get a bunch all at once.
> I would have thought if the database call was timing out I would get a
> timeout
> error.
> The server is Win 2003 (under VMware), and hosts multiple asp and asp.net
> web applications.
> This is a sample of the exception details I'm getting:
> System.Threading.ThreadAbortException: Thread was being aborted.
> at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior
> cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
> at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior
> behavior)
> at
> System.Data.SqlClient.SqlCommand.System.Data.IDbCommand.ExecuteReader(Comm
andBehavior
> behavior)
> at System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32
> startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> CommandBehavior behavior)
> at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32
> startRecord, Int32 maxRecords, String srcTable, IDbCommand command,
> CommandBehavior behavior)
> at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
> at NCSUtilities.DataAccess.ExecuteDataset(SqlConnection connection,
> CommandType commandType, String commandText, SqlParameter[]
> commandParameters)
> at NCSUtilities.DataAccess.ExecuteDataset(String connectionString,
> CommandType commandType, String commandText, SqlParameter[]
> commandParameters)
> I got a suggestion to look at the "DefaultAppPool" properties on the web
> server, but I'm not sure what settings to modify.
> Any ideas on how I could identify the cause or how I could resolve this
> would be greatly appreciated.
> Thanks,
> Keith F
>