-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgram.cs
More file actions
68 lines (61 loc) · 2.07 KB
/
Copy pathProgram.cs
File metadata and controls
68 lines (61 loc) · 2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace PRACTICE_EAD
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
DAL obj = new DAL();
var dt = new PMS.entities.adminDTO();
dt.id = 1;
dt.name = "sadaf";
dt.login = "sadaf";
dto.password = "123";
PMS.BAL.adminBO.save(dto);
var data=PMS.BAL.adminBO.GetAllUser();
var del= PMS.BAL.adminBO.delete(1);
var prod=PMS.BAL.adminBO.GetUserById(1);
var dto = new PMS.entities.userDTO();
dto.id = 1;
dto.name = "saima";
dto.login = "saima";
dto.password = "123";
dto.gender = 'F';
dto.image = "pakistan.jpg";
dto.adress = "lahore";
dto.age = 20;
dto.nic = "123";
dto.dob = DateTime.Now.AddYears(-33);
dto.email ="EAD.SEMorning@gmail.com";
String toAddress = "EAD.SEMorning@gmail.com";
String subject = "Email Testing";
String body = "Code: 123451";
Boolean result = EmailHandler.SendEmail(toAddress, subject, body);
if (result == false)
{
Console.WriteLine("Unable to send email");
}
else
{
Console.WriteLine("Email Sent!");
}
// var id=obj.save2(dto);
PMS.BAL.userBO.save(dto);
var data=PMS.BAL.userBO.GetAllUser();
var del= PMS.BAL.userBO.delete(1);
var prod=PMS.BAL.userBO.GetUserById(1);
System.Console.ReadKey();
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}