Skip to content

Instantly share code, notes, and snippets.

View swaters86's full-sized avatar
🏠
Kicking ass and taking names

Steve Waters swaters86

🏠
Kicking ass and taking names
View GitHub Profile
@inject IDbContextFactory<MyDbContext> DbContextFactory
@implements IAsyncDisposable
<RadzenDataGrid Data="@filteredItems" Count="@totalRecords"
LoadData="@LoadData"
### **Soft Skills for This Individual**
#### **1. Communication Skills**
- **Strong Written Communication**: Excellent at crafting clear, concise, and professional messages via email and Teams, ensuring ideas and updates are understood.
- **One-on-One Communication**: Skilled at building rapport and effectively conveying ideas during phone calls or direct interactions, making them approachable and easy to work with.
- **Asynchronous Collaboration**: Thrives in environments that rely on written communication, like remote or hybrid teams.
---
#### **2. Problem-Solving**
private void FilterDate(FilterDescriptor filter, ref IQueryable<LogWithDetail> query, string columnName)
{
if (!string.IsNullOrEmpty(columnName) && filter.FilterValue != null)
{
// Get the property info for the specified column
var propertyInfo = typeof(LogWithDetail).GetProperty(columnName);
// Ensure the column exists and is of type DateTime
if (propertyInfo != null && propertyInfo.PropertyType == typeof(DateTime))
{
private void FilterDate(FilterDescriptor filter, IQueryable<LogWithDetail> query, string columnName)
{
if (!string.IsNullOrEmpty(columnName) && filter.FilterValue != null)
{
// Get the property info dynamically from the column name
var propertyInfo = typeof(LogWithDetail).GetProperty(columnName);
if (propertyInfo != null && propertyInfo.PropertyType == typeof(DateTime))
{
// Parse the filter value to DateTime
public static string Encrypt(string plainText, byte[] encryptionKey, byte[] iv)
{
using var aes = Aes.Create();
aes.Key = encryptionKey;
aes.IV = iv;
using var encryptor = aes.CreateEncryptor(aes.Key, aes.IV);
using var ms = new MemoryStream();
using var cs = new CryptoStream(ms, encryptor, CryptoStreamMode.Write);
using (var sw = new StreamWriter(cs))
Get-Service -Name "ServiceName" | Select-Object *
# Navigate to the registry key for services
Remove-Item -Path "HKLM:\SYSTEM\CurrentControlSet\Services\ServiceName" -Recurse
# Replace placeholders with appropriate values
$serviceName = "YourServiceName"
$displayName = "Your Service Display Name"
$description = "This is the description of the service."
$executablePath = "C:\Path\To\YourExecutable.exe"
# Create the service
sc.exe create $serviceName binPath= "\"$executablePath\"" DisplayName= "\"$displayName\""
# Add a description (optional but recommended)
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://wixtoolset.org/schemas/v4/wxs">
<Product
Name="Analyze Backfill Manager"
Id="*"
UpgradeCode="66fc43df-90cf-4913-bb94-e5211a057984"
Version="1.0.0.0"
Manufacturer="ABB Analyze"
Language="1033">
@echo off
echo Removing DLL files from Git tracking, but keeping them locally...
git rm --cached -r *.dll || echo *.dll files not found, continuing
echo Removing build directories from Git tracking...
git rm --cached -r [Dd]ebug/ || echo [Dd]ebug/ directory not found, continuing
git rm --cached -r [Dd]ebugPublic/ || echo [Dd]ebugPublic/ directory not found, continuing
git rm --cached -r [Rr]elease/ || echo [Rr]elease/ directory not found, continuing
git rm --cached -r [Rr]eleases/ || echo [Rr]eleases/ directory not found, continuing
git rm --cached -r x64/ || echo x64/ directory not found, continuing
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
</configSections>
<log4net>
<!-- Define some basic settings -->
<appender name="ConsoleAppender" type="log4net.Appender.ConsoleAppender">
<layout type="log4net.Layout.PatternLayout">