473,603 Members | 2,603 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Calling static method like business layer

3 New Member
Hi all,
can someone write me if is normal to have business layer of static methods.

Example: from page.aspx.cs calling static method in other assembly (static methods doesnt use state variables). Can be some problem when more requests will be calling that static method in same time? And How static methods works? That method is created (new instance of some object) when it is calling and in the end is disposed?

Thanks
Aug 27 '09 #1
1 2785
jhardman
3,406 Recognized Expert Specialist
Hi, you accidentally posted in the ASP classic forum, instead of the ASP.NET forum. I have moved it over for you.
Sep 1 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

0
1367
by: Bob | last post by:
I've got a 3-tiered WinForms application in C# .net. The presentation layer (client exe) contains references to the Business layer (dll), and everything works great on the same machine, but when deployed the clients will be on different machines accessed from the network. How does the presentation layer call the Business layer from a different machine? I know I can use WebServices, but that doesn't seem right for an business...
9
2651
by: Laban | last post by:
Hi, I find myself using static methods more than I probably should, so I am looking for some advice on a better approach. For example, I am writing an app that involves quite a bit of database operations on purchase orders and inventory. I have created a PurchaseOrder class and Inventory class to encapsulate operations like creating POs, finding items, etc. These two classes are used extensively from different parts of the app.
7
1542
by: Andrea Williams | last post by:
I would like to be able to create a singleton when using my Error Handling object. It uses a static Instance() method to return the currently activated object. But my question is, since it is static, it is shared between users on a web site? That I would not like since each user needs to have their own instance. Does anyone know the behavior of an object that is create and returned through a static method with ASP.NET? If the Singleton...
15
2151
by: dn | last post by:
I'm starting an n-tier application with an ASP.NET 2.0 presentation layer, a business layer, a data access layer, and a SQL Server 2005 database, and I have a question. In the business and data access layers, should I use static methods? Or, should I code the classes so that they have to be instantiated? I've seen examples of both, and I'm not sure which is the "preferred" or "best" way. Thanks.
2
1414
by: Steve | last post by:
C# I am new to C#, and new to the whole OO concepts, and so I am sure this is a very stupid question, but I'll ask anyway. When should my methods be static? I have several "Business Objects" in my app, which basically hold key functionality. For example I have an Asset class. In there I have some methods for getting various attributes of an asset. For example I have this: public class Asset {
5
6515
by: Thirsty Traveler | last post by:
I am still a little confused on when it makes sense to use static methods. For example, if we have a web page that calls a business logic layer that calls a data access layer, should the method calls be static if no data is stored as state in the components?
5
2213
by: Dinsdale | last post by:
I was discussing class architecture with one of the senior developers at my new job and him and I have a similar idea on how to work with data access and class libraries. That said, our implementations vary slightly and I wanted to post the question to the .Net community to get some feedback. So here is the issue: When designing classes both the senior developer and I agree that data access should be abstracted out from a business object...
6
2484
by: Max2006 | last post by:
Hi, I am trying to make our business logic layer components more efficient. We use strongly typed datasets and TableAdapters. Is it a good idea to use a static TableAdpater to share the static instance among all sessions? My business logic components are like this:
6
11566
by: Ole Nielsby | last post by:
VC has a __cdecl specifier which allows functions and methods to be called with varying parameter count. (I understand this is the default for functions in general but in VC, instances use another convention unless they have an ellipsis argument.) I can force GCC and other compilers to use such a convention by declaring all methods with an ellipsis, but I'd rather not clutter my method definitions with these.
0
7928
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8415
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8405
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8060
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
5878
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5441
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
3903
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
3951
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1259
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.