Controls:-----------Most controls in .NET derive from the System.Windows.Forms.Control class. This class defines the basic functionality of the controls, which is why many properties and events in the controls we'll see are identical. Many of these classes are themselves base classes for other controls, as is the case with the Label and TextBoxBase...
An Example to create an UserControl to create a checklist box and how to set default check in ASP.Net Using C#
using System;using System.Collections;using System.ComponentModel;using System.Drawing;using System.Data;using System.Text;using System.Windows.Forms;namespace MatrixControl{ public partial class M42CheckBoxControl : UserControl { private static int index = 0; public M42CheckBoxControl() { InitializeComponent();...
How to Send data from a User Control to another user control on a single form using Events and Delegates:--
This is an example how to create Dynamic Check Boxes and how to communicate betwwen two user controls on a sigle form using Events and Delegates.In this application I have to send some data from control2 to control1 on a single button click.So for this i have used event and Delegates.Have A look.//Control2:----namespace ParserF{ public partial class...
Nagarro Placement Papers..
Ques.1 :- Seat Reservation prog for the theatre. Write a function for seat allocation for the movie tickets. Total no of seats available are 200. 20 in each row. Each row is referred by the Character, "A" for the first row and 'J' for the last. And each seat in a row is represented by the no. 1-20. So seat in diffrent rows would be represented as A1,A2....;B1,B2.....;........J1,J2......
C Aptitude Questions...
C Questions Check Your Ability In CNote : All the programs are tested under Turbo C/C++ compilers. It is assumed that, Programs run under DOS environment, The underlying machine is an x86 system, Program is compiled using Turbo C/C++ compiler.The program output may depend on the information based on this assumptions (for example sizeof(int) ==...
C code to Check the string has valid identifier or not in.
#include#include#includechar keyword[][10]={"auto","break","case","char","const","continue","default","printf", "double","else","enum","extern","float","for","goto","if","int","do", "long","register","return","short","signed","sizeof","static","struct","switch","typedef","union","unsigned","void","volatile","while"};...
Code for matrix problem in C++
#includeusing namespace std;#define row 10#define col 10int row1,row2,col1,col2;class matrix{ int a[row][col]; int b[row][col]; int c[row][col]; public : void input(); void addtion(); void subtraction(); void multiply(); void show();};void matrix::input(){ int i,j; cout<<"enter the number of...
Implementation of a queue in C++
#includeusing namespace std;class queue{ int front,rear; int item[3]; public: void insert(int); int remove(); void display(); void setvalues() { front=-1; rear=0; } };void queue::insert(int m){ item[rear++]=m;}int queue::remove(){int x; if(front==-1)cout<<"empty"; x=item[++front];...
A linked list program in C++
#includeusing namespace std;struct node{ int info; struct node *next; struct node *getnode(); struct node *insert_last(struct node *); struct node *insert_begin(struct node *); struct node *insert_after(struct node *); struct node *delete_after(struct node *); void display(struct node *);};struct node* node:: getnode(){ int x;...
OOPS Concepts..
Q:-What is Function Overloading ?A:-Function overloading: C++ enables several functions of the same name to be defined, as long asthese functions have different sets of parameters (at least as far as their types are concerned). Thiscapability is called function overloading. When an overloaded function is called, the C++ compilerselects the proper function...
OOPS Concepts...
Q:-What is namespace?A:-Namespaces allow us to group a set of global classes, objects and/or functions under a name. To sayit somehow, they serve to split the global scope in sub-scopes knownas namespaces.The form to use namespaces is:namespace identifier { namespace-body }Where identifier is any valid identifier and namespace-body is the set of classes,...
1. What is virtual constructors/destructors?Virtual destructors: If an object (with a non-virtual destructor) is destroyed explicitly by applyingthe delete operator to a base-class pointer to the object, the base-class destructor function(matching the pointer type) is called on the object.There is a simple solution to this problem – declare a virtual...
How to: Read Image Metadata
Some image files contain metadata that you can read to determine features of the image. Like, a digital photograph might contain metadata that you can read to determine the Author,Title and Keywords of the image.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ImageMetaData.aspx.cs" Inherits="ImageMetaData" %>
Untitled Page
...
How to store a record in xml file from a windows form and extract through Reflection..(A perfect example of reflection)
Reflection.cs Browse folder to store record in xml file and again browse to extract from the xml file all the properties are setting in settings.cs and all constants are defined in Constants.cs and Reflection.Designer contains the designer view..using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using...
Sudoku-Checker in ASP.Net using C#
# region directivesusing System;using System.Collections;#endregionnamespace sudokuChecker{ class SudokuMainExample { static void Main() { SudokuCheck objectSudokuCheck = new SudokuCheck(); int[,] Board=new int[9,9]; int countnumberofInput=0; string menuStatus="y"; string...