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 BindableExtender { | |
public static string GetBindableText(DependencyObject obj) { | |
return (string)obj.GetValue(BindableTextProperty); | |
} | |
public static void SetBindableText(DependencyObject obj, | |
string value) { | |
obj.SetValue(BindableTextProperty, value); | |
} |
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
db.Database.SqlCommand("dbo.News_Insert @Title, @Body, @NewsStatusId", | |
new SqlParameter("Title", news.Title), | |
new SqlParameter("Body", news.Body), | |
new SqlParameter("NewsStatusId", news.NewStatus.Id)); |
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
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, Inherited = true, AllowMultiple = true)] | |
public class SessionExpireFilterAttribute : ActionFilterAttribute | |
{ | |
public override void OnActionExecuting(ActionExecutingContext filterContext) | |
{ | |
var ctx = HttpContext.Current; | |
if (ctx.Session["RegisteredUser"] == null || !filterContext.HttpContext.Request.IsAuthenticated) | |
{ | |
FormsAuthentication.SignOut(); | |
ctx.Session.Clear(); |
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
declare @selecteddate date = cast(getdate() as date); | |
SELECT * | |
FROM foo | |
WHERE Date >= DATEADD(day, 0, convert(date, @selecteddate)) and Date < DATEADD(day, 1, convert(date, @selecteddate)) | |
Examples | |
declare @selecteddate date = cast(getdate() as date); --today | |
declare @selecteddate date = cast(getdate() -1 as date); --yesterday |
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
## bug tracking applications for developers | |
+ [BugLog](http://www.bugloghq.com/) (opensource) | |
+ [BugNET Issue Tracker](http://www.bugnetproject.com/) (commercial, opensource) | |
+ [Trac](http://trac.edgewall.org/) | |
+ [Bugzilla](http://www.bugzilla.org/) (opensource) | |
+ [Snowy Evening](https://snowy-evening.com/) | |
+ [MantisBT](http://www.mantisbt.org/) (commercial, free plan) | |
+ [Bugify](https://bugify.com/) (commercial) | |
+ [Lighthouse](http://lighthouseapp.com/) (commercial) | |
+ [TheBuggenie](http://www.thebuggenie.com/) (commercial) |
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
## Font Combinations | |
+ [Beatiful Web Type Combinations](http://bueltge.de/free-web-font-combinations/) | |
+ [Typ.io](http://www.typ.io/) | |
+ [Google Web Fonts Typographic Project](http://femmebot.github.io/google-type/) | |
+ [Discover.typograhy](http://discover.typography.com/) | |
+ [I Font You](http://ifontyou.com/) | |
+ [Type Connection](http://www.typeconnection.com/) | |
+ [Beatiful Web Type](http://hellohappy.org/beautiful-web-type/) | |
+ [Typewolf](http://www.typewolf.com/) | |
+ [Just my type](http://justmytype.co/) |
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
## web conferencing tools | |
+ [vyew](http://vyew.com/s/) | |
+ [onwebinar](http://www.onwebinar.com/) | |
+ [meetingburner](https://www.meetingburner.com/) | |
+ [big blue button](http://bigbluebutton.org/overview/) | |
+ [managemeet](https://www.managemeet.com/) | |
+ [sync](http://sync.in/) | |
+ [show document](http://www.showdocument.com/) | |
+ [webhuddle](https://www.webhuddle.com/) | |
+ [anymeeting](http://www.anymeeting.com/) |
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 Crud | |
{ | |
public static int Save<T>(this T entity, ZeiterfassungsContext ctx) where T : class, ICrud | |
{ | |
if (entity == null) | |
throw new ArgumentNullException("entity", "Die Entität darf nicht null sein"); | |
return Exists(entity, "Id", ctx) ? Update(entity, ctx) : Insert(entity, ctx); | |
} | |
public static int Insert<T>(this T entity, ZeiterfassungsContext ctx) where T : class, ICrud |
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 checkPassword(pass) { | |
var numbers = pass.match(/\d+/g); | |
var uppers = pass.match(/[A-Z]/); | |
var lowers = pass.match(/[a-z]/); | |
var special = pass.match(/[!@#$%\^&*\+]/); | |
if (numbers === null || uppers === null || lowers === null || special === null) | |
valid = false; |
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 WaitAndRetry | |
{ | |
public static void Do(Action action, TimeSpan waitInterval, int retryCount = 3) | |
{ | |
Do<object>(() => { action(); return null; }, | |
waitInterval, retryCount); | |
} | |
public static T Do<T>(Func<T> action, TimeSpan waitInterval, int retryCount = 3) | |
{ |
OlderNewer