This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.Mvc; | |
using Registration_module.Models; | |
using System.IO; | |
using System.Web.Helpers; | |
using Dapper; | |
using System.Text; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public bool AddOrder(Order model) | |
{ | |
try | |
{ | |
XDocument OrderDetails = new XDocument(new XDeclaration("1.0", "UTF - 8", "yes"), | |
new XElement("CustomerOrder", | |
from OrderDet in model.Products | |
select new XElement("OrderDetails", | |
new XElement("ItemCode", OrderDet.ItemCode), | |
new XElement("Description", OrderDet.Description), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.Mvc; | |
using ERP_MULTI.Models; | |
namespace ERP_MULTI.Controllers | |
{ | |
public class AdminController : Controller |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public ActionResult sendmail() | |
{ | |
return View(); | |
} | |
[HttpPost] | |
public ActionResult sendmail(Practice_mvc.Models.MailModel _objModelMail) | |
{ | |
if (ModelState.IsValid) | |
{ | |
MailMessage mail = new MailMessage(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.Mvc; | |
namespace Practice_mvc.Controllers | |
{ | |
public class HomeController : Controller | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
int main(){ | |
int n,i,m=0,flag=0; | |
printf("Enter the number to check prime:"); | |
scanf("%d",&n); | |
m=n/2; | |
for(i=2;i<=m;i++) | |
{ | |
if(n%i==0) | |
{ |