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

Web Service vs C# Dll

P: n/a
Bob
Hi Al

I would just like to know, When I am developing my C# Windows application, would it be better for me in the long run, to make Web services instead of DLL's so that when/if eventually we have a Web application that needs the same functions, it will be easier to integrate this web service, or should I rather create a DLL for the C# application and a web service for the Web application? Are there any differences between the webservice and a DLL like performance degradation etc

Thanks in advanc

Bob
Nov 15 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Implement the functionality in a standalone assembly and design it so that
it can be controlled from a GUI using public classes/methods. That will set
you up for alternative front ends, like web services. Build your initial
WinForms client around the DLL.

There's little or no performance degradation.

--
____________________
Klaus H. Probst, MVP
http://www.vbbox.com/

"Bob" <an*******@discussions.microsoft.com> wrote in message
news:13**********************************@microsof t.com...
Hi All

I would just like to know, When I am developing my C# Windows application, would it be better for me in the long run, to make Web services instead of
DLL's so that when/if eventually we have a Web application that needs the
same functions, it will be easier to integrate this web service, or should I
rather create a DLL for the C# application and a web service for the Web
application? Are there any differences between the webservice and a DLL like
performance degradation etc.
Thanks in advance

Bob

Nov 15 '05 #2

P: n/a
Bob,

If I understand you correctly when you say, "performance degredation"
meaning "is there a penalty for" then, yes, there is a performance penalty
for using a WebService over a DLL which resides on disk. WebServices require
marshalling of data, SOAP calls and the like, whereas your on-disk DLL, once
JITTed, has literally no penalties in comparison to native code.

Build it as a DLL.
"Bob" <an*******@discussions.microsoft.com> wrote in message
news:13**********************************@microsof t.com...
Hi All

I would just like to know, When I am developing my C# Windows application, would it be better for me in the long run, to make Web services instead of
DLL's so that when/if eventually we have a Web application that needs the
same functions, it will be easier to integrate this web service, or should I
rather create a DLL for the C# application and a web service for the Web
application? Are there any differences between the webservice and a DLL like
performance degradation etc.
Thanks in advance

Bob

Nov 15 '05 #3

P: n/a
Jax
So when is the best time, or right time to use web services?
Nov 15 '05 #4

P: n/a
I may not necessarily be the best person to answer this, but in my opinion
the best time to write a webservice is when you're trying to create a
cross-platform solution, or a solution that already has, say, a web and
client-side implementation.

I don't see it difficult to take the same assemblies that you use for
building your Windows application and use them to power the web-service in
the future. I also don't see any reason for your clientside app to take the
performance hit (and the necessity to be online) when there doesn't exist a
web application on the possibility that there may be one someday.

Ben

"Jax" <an*******@discussions.microsoft.com> wrote in message
news:FB**********************************@microsof t.com...
So when is the best time, or right time to use web services?

Nov 15 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.