This file contains 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
function Get-ComPortNames { | |
param ( | |
[string]$VendorID, | |
[string]$ProductID | |
) | |
$pattern = "^VID_$VendorID.PID_$ProductID" | |
$rx = New-Object System.Text.RegularExpressions.Regex($pattern, [System.Text.RegularExpressions.RegexOptions]::IgnoreCase) | |
$comports = @() | |
$rk1 = [Microsoft.Win32.Registry]::LocalMachine |
This file contains 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.Text; | |
using System.Threading.Tasks; | |
using Microsoft.Win32; | |
namespace WorkstationId | |
{ | |
class Program |
This file contains 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 class BolConstraint | |
{ | |
public string Origin; | |
public string Destination; | |
public string CarrierId; | |
public DateTime PickupDate; | |
public DateTime Timestamp; | |
} |
This file contains 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 class Original | |
{ | |
public string OldFunction(string s1, string s2) | |
{ | |
return s1 + s2; | |
} | |
} | |
public class RobertsSolution |
This file contains 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
<h2>title</h2> | |
@ViewBag.SellerHandle |
This file contains 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 Microsoft.AspNet.Identity | |
<!-- do we have a user --> | |
@if (Request.IsAuthenticated) | |
{ | |
<!-- we have user, so display user name. --> | |
<div class="username"> | |
@User.Identity.GetUserName() | |
</div> | |
} |
This file contains 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
package paging | |
import "fmt" | |
// SearchWindow contains start and stop | |
// and a default method for spliting the | |
// window into smaller windows | |
type SearchWindow struct { | |
start int64 | |
stop int64 |
This file contains 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
ALTER FUNCTION [dbo].[Creative_Grid] ( | |
@start DATETIME, | |
@end DATETIME, | |
@clientIds VARCHAR(MAX), | |
@seId VARCHAR(MAX) = null, | |
@campaignId VARCHAR(MAX) = null, | |
@adCategoryId VARCHAR(MAX) = null | |
) | |
RETURNS TABLE AS RETURN |
This file contains 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 static class ReportExtensions | |
{ | |
public static string Serialize(this Report report) | |
{ | |
var stream = SerializeToStream(report); | |
var finalString = ReadStream(stream); | |
return finalString; | |
} |
This file contains 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
<?xml version="1.0" encoding="utf-8" ?> | |
<configuration> | |
<configSections> | |
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" > | |
<section name="Mashery.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" /> | |
</sectionGroup> | |
</configSections> | |
<applicationSettings> | |
<Mashery.Properties.Settings> | |
<setting name="ApiKey" serializeAs="String"> |
NewerOlder