با سلام



using System;
using System.Collections.Generic;
using System.Text;
namespace DataLayer.Models
{
public class UserInformation
{
public int UserId { get; set; }
public string UserName { get; set; } = "admin";
public string UserPassword { get; set; } = "admin";
}
}
using Barnamenevis.Net.RtlMessageBox.WindowsForms;
using DataLayer.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace BookKeeper
{
public partial class frmLogin : Form
{
public frmLogin()
{
InitializeComponent();
}
private void frmLogin_Load(object sender, EventArgs e)
{
}
private void btnLogin_Click(object sender, EventArgs e)
{
UserInformation userInformation = new UserInformation();
if (txtUserName.Text.Trim().ToLower() == userInformation.UserName && txtPassword.Text.Trim().ToLower() == userInformation.UserPassword)
{
DialogResult = DialogResult.OK;
}
else
{
RtlMessageBox.Show("رمز عبور یا نام کاربری اشتباه است", "خطا", System.Windows.MessageBoxButton.OK, System.Windows.MessageBoxImage.Warning);
}
}
}
}
عالی بود
یه فونت خوب کم داره
ممنونم 🙏
چشم. چطوره؟

عالی