Brought from our old site: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1349&title=Allow%20Page%20Access%20only%20to%20the%20Logged%20in%20Users Allow Page Access only to the Logged in Users It’s common across many sites that you allow certain pages of your site only to the logged in users. Here, I am providing a simple way to do that in your site The main idea is, when users’ credentials are …
Category: FromSitesTree.com
Sep 01
A Simple ASP.Net Form in C#. Payment Information Collection Form #.Net Web Applications
Brought from our old site: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1350&title=A%20Simple%20ASP.Net%20Form%20in%20C#.%20Payment%20Information%20Collection%20Form. A Simple ASP.Net Form in C#. Payment Information Collection Form. Such forms can be used to test payment processing API/Service before actually integrating. The input fields are to send data to the payment gateway. The response fields are to display response from payment gateway. Here, the output fields represent …
Sep 01
Encryption and .Net #.Net Web Applications
Brought from our old site: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1355&title=Encryption%20and%20.Net Encryption and .Net Dot net provides rich support for data encryption. the namespace System.Security.Cryptography includes the encryption features. There are three primary concepts related to encryption such as Hashing, Symmetric Encryption, and Asymmetric encryption. A hash is a data fingerprint, a small data that represents the uniqueness of a …
Sep 01
ASP.Net Validation Control Examples in C# #.Net Web Applications
Brought from: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1325&title=ASP.Net%20Validation%20Control%20Examples%20in%20C#. ASP.Net Validation Control Examples. Just check the code below Some notes RequiredFieldValidator: is used to check that a field is filled up CompareValidator: Compare the value of a field with another field or data RangeValidator: Compares the data is within a given range RegularExpressionValidator: Domain name syntax, email addtress syntax ValidationSummary: Display …
Sep 01
Simple Ajax Applications in C# (ASP.Net) #.Net Web Applications
Brought from: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1347&title=Simple%20Ajax%20Applications%20in%20C#%20(ASP.Net) Simple Ajax Applications in C# (ASP.Net) Note:asmx web-service might be more appropriate in some/many cases If you are coming from PHP or Java Platform where you use JavaScript or jQuery to provide Ajax functionality, you still can use those strategies in ASP.net to provide Ajax functionality Check our short note on Ajax …
Sep 01
Creating your own Classes in C# in ASP.net #.Net Web Applications
Brought from our old site: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1348&title=Creating%20your%20own%20Class%20in%20C#%20in%20ASP.net Creating your own Class in C# in ASP.net It is kind of simple. You need to create a class library. The class library will create a dll file. From your project, you need to add reference to the dll file. Then you will be able to use the classes …
Aug 31
Random C# and MS SQl Server #.Net Web Applications
Brought from: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1321&title=Random%20C#%20and%20MS%20SQl%20Server Foreign Key in Table Declaration CREATE TABLE ORDERS ( ID integer primary key, Order_Date datetime, Customer_ID integer references CUSTOMER(ID), Amount double ); ALTER TABLE ORDERS ADD FOREIGN KEY (customer_id) REFERENCES CUSTOMER(ID); Stored Procedure Example CREATE PROCEDURE [dbo].[procedure_name] @param1 VARCHAR(100) ,@param2 VARCHAR(200) OUTPUT AS BEGIN DECLARE @param3 VARCHAR(100) SET @param3 = ‘ ‘ …
Aug 31
Manipulating Configuration Parameters: For example Variables in web.config #.Net Web Applications
Brought from (our old site): http://salearningschool.com/displayArticle.php?table=Articles&articleID=1324&title=Manipulating%20Configuration%20Parameters:%20For%20example%20Variables%20in%20web.config To access a variable value, you can use the following type of code string statusr = WebConfigurationManager.AppSettings[“userLoginStatus”].ToString(); You will need to use: using System.Web.Configuration; or you can write as follows: string statusr = System.Web.Configuration.WebConfigurationManager.AppSettings[“userLoginStatus”].ToString(); What about if you want to change the values of the variables in the web.config …
Aug 31
Random Notes and simple code on Developing Web Sites (Applications) in ASP.net using C# #.Net Web Applications
Brought from: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1319&title=Random%20Notes%20and%20simple%20code%20on%20Developing%20Web%20Sites%20(Applications)%20in%20ASP.net%20using%20C# And sure, pretty old article.. Random Notes and simple code on Developing Web Sites (Applications) in ASP.net using C# The information below primarily apply to the web page model of web-development in C# _PageStart.cshtml runs at each page start/open _AppStart.cshtml runs at the beginning of the application Syntax to use the Layout …
Aug 31
Razor, Web-page Model, Web-Application Development in C# #.Net Web Applications
Brought from: http://salearningschool.com/displayArticle.php?table=Articles&articleID=1320&title=Razor,%20Web-page%20Model,%20Web-Application%20Development%20in%20C# (written long back) Razor, Web-page Model, Web-Application Development in C# Razor:a markup syntax to add server side code into ASP.net pages Razor example: Current time is @DateTime.Now Razor Code Syntax Single statement block @{ var message = “Hello World”; } Inline expression or variable The message: @message Multi-statement block @{ var greeting …
