public void SetPlayProperties() { // Title suffix for problem with covers and movie with the same name string strThumb = GetStrThumb(); GUIPropertyManager.SetProperty("#Play.Current.Director", Director); GUIPropertyManager.SetProperty("#Play.Current.Genre", Genre); GUIPropertyManager.SetProperty("#Play.Current.Cast", Cast); GUIPropertyManager.SetProperty("#Play.Current.DVDLabel", DVDLabel); GUIPropertyManager.SetProperty("#Play.Current.IMDBNumber", IMDBNumber); GUIPropertyManager.SetProperty("#Play.Current.File", File); GUIPropertyManager.SetProperty("#Play.Current.Plot", Plot); GUIPropertyManager.SetProperty("#Play.Current.PlotOutline", PlotOutline); GUIPropertyManager.SetProperty("#Play.Current.UserReview", UserReview); // Added GUIPropertyManager.SetProperty("#Play.Current.Rating", Rating.ToString()); GUIPropertyManager.SetProperty("#Play.Current.TagLine", TagLine); GUIPropertyManager.SetProperty("#Play.Current.Votes", Votes); GUIPropertyManager.SetProperty("#Play.Current.Credits", WritingCredits); GUIPropertyManager.SetProperty("#Play.Current.Thumb", strThumb); GUIPropertyManager.SetProperty("#Play.Current.Title", Title); GUIPropertyManager.SetProperty("#Play.Current.Year", Year.ToString()); GUIPropertyManager.SetProperty("#Play.Current.Runtime", RunTime.ToString()); GUIPropertyManager.SetProperty("#Play.Current.MPAARating", MPARating); string strValue = "no"; if (Watched > 0) { strValue = "yes"; } GUIPropertyManager.SetProperty("#Play.Current.IsWatched", strValue); }
public void SetProperties(bool isFolder) { // Title suffix for problem with covers and movie with the same name string strThumb = GetStrThumb(); GUIPropertyManager.SetProperty("#director", Director); GUIPropertyManager.SetProperty("#genre", Genre); GUIPropertyManager.SetProperty("#cast", Cast); GUIPropertyManager.SetProperty("#dvdlabel", DVDLabel); GUIPropertyManager.SetProperty("#imdbnumber", IMDBNumber); GUIPropertyManager.SetProperty("#file", File); GUIPropertyManager.SetProperty("#plot", Plot); GUIPropertyManager.SetProperty("#plotoutline", PlotOutline); GUIPropertyManager.SetProperty("#userreview", UserReview); // Added GUIPropertyManager.SetProperty("#rating", Rating.ToString()); GUIPropertyManager.SetProperty("#tagline", TagLine); GUIPropertyManager.SetProperty("#votes", Votes); GUIPropertyManager.SetProperty("#credits", WritingCredits); GUIPropertyManager.SetProperty("#thumb", strThumb); GUIPropertyManager.SetProperty("#title", Title); GUIPropertyManager.SetProperty("#year", Year.ToString()); GUIPropertyManager.SetProperty("#runtime", RunTime.ToString()); GUIPropertyManager.SetProperty("#mpaarating", MPARating); string strValue = "no"; if (Watched > 0 && !isFolder) { strValue = "yes"; } if (isFolder) { strValue = string.Empty; } GUIPropertyManager.SetProperty("#iswatched", strValue); }
internal string StoreSummaryResults() { string tablestyle = " style='border:solid #4472C4 1.0pt; text-align:center; cellpadding=0px; border-collapse:collapse; font-family: Calibri, sans-serif; size: 11pt; '"; string headerrowstyle = " style='background-color: #4472C4; color: #FFF; height:.2in; '"; string datarowstyle = " style='color: #000; height:.2in; '"; string tdstring = " width='156' style='width:116.85pt; border:solid #4472C4 1.0pt; text-align:center; padding:0in 5.4pt'"; string tdcounts = " width='96' style='width:1.0in; border:solid #4472C4 1.0pt;'"; string failcolor = "#F63438;"; string errcolor = "#F63438;"; if (TestFailureCount == 0) { failcolor = " #000'"; } if (TestErrorCount == 0) { failcolor = " #000'"; } string tdstylefail = " width='96' style='width:1.0in; border:solid #4472C4 1.0pt; color: " + failcolor + "'"; string tdstyleerror = " width='96' style='width:1.0in; border:solid #4472C4 1.0pt; color: " + errcolor + "'"; StringBuilder sb = new StringBuilder(); //header sb.Append("<table" + tablestyle + ">"); sb.Append("<tr" + headerrowstyle + ">"); sb.Append("<td" + tdstring + ">"); sb.Append("App.Browser</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append("Tests Run</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append("Passed</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append("Failures</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append("Errors</td>"); sb.Append("<td" + tdstring + ">"); sb.Append("Run Time (Sec)</td>"); sb.Append("</tr>"); //data sb.Append("<tr" + datarowstyle + ">"); sb.Append("<td" + tdstring + ">"); sb.Append(AppName + "." + AppBrowser + "</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append(TestsRun + "</td>"); sb.Append("<td" + tdcounts + ">"); sb.Append(TestPassedCount + "</td>"); sb.Append("<td" + tdstylefail + ">"); sb.Append(TestFailureCount + "</td>"); sb.Append("<td" + tdstyleerror + ">"); sb.Append(TestErrorCount + "</td>"); sb.Append("<td" + tdstring + ">"); sb.Append(RunTime.ToString("##.#####") + "</td>"); sb.Append("</tr></table>"); return(sb.ToString()); }
public override string ToString() { if (InstrumentSerialNumber == string.Empty) { return(string.Format("{0},SN={1},LastRun={2},EventTime={3},{4},Pos={5},SWV={6}", EventCode.Code, SerialNumber, RunTime.ToString(DATETIME_FORMAT), EventTime.ToString(DATETIME_FORMAT), Passed ? "Passed" : "Failed", Position, SoftwareVersion)); } else { return(string.Format("{0},SN={1},Inst={2},LastRun={3},LastDock={4},{5},Pos={6},SWV={7}", EventCode.Code, SerialNumber, InstrumentSerialNumber, RunTime.ToString(DATETIME_FORMAT), EventTime.ToString(DATETIME_FORMAT), Passed ? "Passed" : "Failed", Position, SoftwareVersion)); } }
public override void WriteXml(XmlWriter writer) { writer.WriteAttributeString("ItemID", ItemID); writer.WriteAttributeString("MinBuyout", MinBuyout.ToString()); writer.WriteAttributeString("MaxBuyout", MaxBuyout.ToString()); writer.WriteAttributeString("RunTime", RunTime.ToString()); writer.WriteAttributeString("Amount", Amount.ToString()); writer.WriteAttributeString("StackSize", StackSize.ToString()); writer.WriteAttributeString("AmountType", AmountType.ToString()); writer.WriteAttributeString("AutoFindAh", AutoFindAh.ToString()); writer.WriteAttributeString("BidPrecent", BidPrecent.ToString(CultureInfo.InvariantCulture)); writer.WriteAttributeString("UndercutPrecent", UndercutPrecent.ToString(CultureInfo.InvariantCulture)); writer.WriteAttributeString("UseCategory", UseCategory.ToString()); writer.WriteAttributeString("Category", Category.ToString()); writer.WriteAttributeString("SubCategoryType", SubCategory.GetType().Name); writer.WriteAttributeString("SubCategory", SubCategory.ToString()); writer.WriteAttributeString("X", loc.X.ToString()); writer.WriteAttributeString("Y", loc.Y.ToString()); writer.WriteAttributeString("Z", loc.Z.ToString()); writer.WriteAttributeString("PostIfBelowMinBuyout", PostIfBelowMinBuyout.ToString()); }
public override string ToString() { string str = ""; if (RunTime == TimeSpan.Zero && RunTimeList.Count == 0) { return("未进行过测试"); } else { if (RunTime != TimeSpan.Zero) { str = "单次测试结果:" + Environment.NewLine; if (haveResult) { str += "返回值:" + Result + Environment.NewLine; } str += " 执行时间:" + RunTime.ToString() + Environment.NewLine; } if (RunTimeList.Count > 0) { str += "多次测试结果:" + Environment.NewLine; for (int i = 0; i < RunTimeList.Count; i++) { str += string.Format("{0:000}", i) + ": "; if (haveResult) { str += "返回" + string.Format("{0,36}", ResultList[i]); } str += " 执行时间 " + RunTimeList[i].ToString() + Environment.NewLine; } } if (CausedException != null) { str += "发生过异常:" + Environment.NewLine + CausedException.ToString(); } return(str); } }
public string FormatforQAD() { const char MFLD = '\u0001'; string mstr = RoutingCode + "\v" + "S" + MFLD; mstr = mstr + Operation.ToString() + "\v" + "I" + MFLD; mstr = mstr + StartDate.ToString() + "\v" + "D" + MFLD; mstr = mstr + EndDate.ToString() + "\v" + "D" + MFLD; mstr = mstr + StandOp + "\v" + "S" + MFLD; mstr = mstr + WorkCenter + "\v" + "S" + MFLD; mstr = mstr + Machine + "\v" + "S" + MFLD; mstr = mstr + Description + "\v" + "S" + MFLD; mstr = mstr + MachPerOp.ToString() + "\v" + "I" + MFLD; mstr = mstr + OverlapUnits.ToString() + "\v" + "I" + MFLD; mstr = mstr + QueueTime.ToString() + "\v" + "G" + MFLD; mstr = mstr + WaitTime.ToString() + "\v" + "G" + MFLD; mstr = mstr + "yes" + "\v" + "L" + MFLD; mstr = mstr + SubcontractLT.ToString() + "\v" + "I" + MFLD; mstr = mstr + SetupCrew.ToString() + "\v" + "G" + MFLD; mstr = mstr + RunCrew.ToString() + "\v" + "G" + MFLD; mstr = mstr + SetupTime.ToString() + "\v" + "G" + MFLD; mstr = mstr + RunTime.ToString() + "\v" + "F" + MFLD; mstr = mstr + MoveTime.ToString() + "\v" + "G" + MFLD; mstr = mstr + YieldPerc.ToString("000") + "\v" + "E" + MFLD; mstr = mstr + ToolCode + "\v" + "S" + MFLD; mstr = mstr + Supplier + "\v" + "S" + MFLD; mstr = mstr + InvValue.ToString() + "\v" + "G" + MFLD; mstr = mstr + SubCost.ToString() + "\v" + "G" + MFLD; mstr = mstr + Comments + "\v" + "X" + MFLD; mstr = mstr + WIP + "\v" + "S" + MFLD; mstr = mstr + PurchaseOrder + "\v" + "S" + MFLD; mstr = mstr + Line.ToString() + "\v" + "I" + MFLD; mstr = mstr + "yes" + "\v" + "L" + MFLD; mstr = mstr + "no" + "\v" + "L" + MFLD; mstr = mstr + OrigStartDate.ToString() + "\v" + "D" + MFLD; mstr = mstr + '\u0014'; return(mstr); }