Categories
Program Ruby Tutorial

HackerRank – 30 Days of Code – Day 5: Loops – Ruby Program

Objective In this challenge, we’re going to use loops to help us do some simple math. Check out the Tutorial tab to learn more. Task Given an integer, n, print its first 10 multiples. Each multiple n x i (where 1<=i<=10) should be printed on a new line in the form: n x i = […]

Categories
Program Ruby Tutorial

HackerRank – 30 Days of Code – Day 4: Class vs. Instance – Ruby Program

Objective In this challenge, we’re going to learn about the difference between a class and an instance; because this is an Object Oriented concept, it’s only enabled in certain languages. Check out the Tutorial tab for learning materials and an instructional video! Task Write a Person class with an instance variable, age, and a constructor […]

Categories
Program Ruby Tutorial

HackerRank – 30 Days of Code – Day 3: Intro to Conditional Statements – Ruby Program

Objective In this challenge, we’re getting started with conditional statements. Check out the Tutorial tab for learning materials and an instructional video! Task Given an integer, n, perform the following conditional actions: If n is odd, print Weird If n is even and in the inclusive range of 2 to 5, print Not Weird If […]

Categories
Program Tutorial

Complete list of CCAvenue Response code with description

CCAvenue Response Codes Name Description Type (length) order_id Unique ID sent by the merchant at the time of initiating the transaction. Alphanumeric (30) tracking_id Unique payment reference number generated by CCAvenue for each order. Numeric (12) bank_ref_no Reference number generated by the bank for the transaction. Alphanumeric order_status Status of the transaction. Alphabets (15) Success […]

Categories
Automation Capybara Program Software Testing

Getting started in Capybara! – A web application automation framework (Sample Program)

About Capybara Capybara is an automation testing framework based on Ruby & Cucumber tool. Capybara is also an Acceptance Testing Framework for a web application. It supports different web drivers to interact with web browsers such as Rack, Selenium, and WebKit. Pre-Requisites for Capybara Ruby Ruby Development Kit Bundler (Optional) Ansicon (Optional) – for colored output Text […]

Categories
C# / .NET Program Tutorial

How to integrate CCAvenue payment gateway into ASP.NET Razor website? (with steps & screenshots)

Hi All, this tutorial is about CCAvenue payment gateway integration for ASP.NET Razor website (.CSHTML). If you are using ASP.NET web pages (.ASPX) you can check the tutorial here. Pre-Requisites Visual Studio 2012 or Latest CCAvenue Active account with Merchant ID Encryption Key Access Code CCAvenue Integration Kit for ASP.NET Custom ASP.NET Integration Kit for Razor […]

Categories
C# / .NET Program Tutorial

How to send email using C# Razor Syntax (with Sample Code)

Step 1: Create the CSHTMLfile Step 2: Create a form with similar to shown below. Step 3:  Use IsPost() to check whever your webpage gets refreshed. i.e if IsPost() is false, your page have not refreshed. So, no need to perform any action. If IsPost() is true, your page is refreshed. You can get the values […]

Categories
C# / .NET Program

C# Abstract Keyword

Abstract is a Keyword & Access Modifier similar to public, private, protected. As name implies Abstract keyword is an template like modifier. It is an incomplete method, class, properties, indexes and events. Which should be completed in derived class. Abstract class are always base class. The members in the abstract class to be implement by the […]

Categories
C# / .NET Program Tutorial

C# (ASP.NET) Program for Sending a Email with Attachment (with explanation)

Read my  previous post “sending email in C#” to understand the basic of STMP. Now, we are going to send a email with attachment. The attachment may be any format. Snippet for creating Attachment object is Attachment attach = new Attachment(string filepath); Access this attachment in MailMessage Object mailMsg.Attachments.Add(attach); Full Program: using System; using System.Net; […]

Categories
C# / .NET Program Tutorial

C# Program to send email through STMP (with Authentication) – asp.net

Step to program to send Email through C#: 1. Initialize the required inputs: In our program, we have provided Name, Email, Phone number, Subject and Message as the string datatype and assigned values to those strings. 2. Create the Object for SmtpClient SmtpClient mailSender = new SmtpClient(); Assign the values to the mailSender object. Some […]