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

How to determine running environment: desktop or web?

P: n/a
Don
I've got a DLL that needs to do different things based on whether or not the
app that's referencing it is a desktop app (e.g. typical VB.NET compiled
app) or web app (e.g. ASP.NET project running on IIS). Is there any VB.NET
method that tells you this kind of information, whether the app using the
dll at that time is a web app or desktop app?

- Don
Nov 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
One quick way that I can think of would be to check the
ExecutingDirectory directory. If it is system32 then your are must
likely in a Web application.

"Don" <un*****@oblivion.com> wrote in message
news:U%AIc.82498$WB5.54286@pd7tw2no:
I've got a DLL that needs to do different things based on whether or not
the
app that's referencing it is a desktop app (e.g. typical VB.NET compiled
app) or web app (e.g. ASP.NET project running on IIS). Is there any
VB.NET
method that tells you this kind of information, whether the app using
the
dll at that time is a web app or desktop app?

- Don


Nov 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.