/// <summary> /// Вывод информации на richTextBox rtb_TrackInformation на вкладке Track_JSON главного окна /// </summary> private void DisplayTrackInformation() { string track = tb_TrackCode.Text; Tracker_track24.getSingleTrackInfo(track); Dictionary <string, Dictionary <string, string> > TrackCodeInfoDictionary = Tracker_track24.getTrackInfoDictionary(); string Text = String.Format( ">>>>>>>>>> {0} <<<<<<<<<< \n" + "===============================================\n" + "Статус: {1}\n" + "Место изменения статуса: {2}\n" + "Время изменения статуса: {3}\n" + "Вес посылки: {4}\n" + "Почтовая компания: {5}\n" + "===============================================\n\n" + "===JSON========================================\n", tb_TrackCode.Text, TrackCodeInfoDictionary[track]["operationAttribute"], TrackCodeInfoDictionary[track]["operationPlaceName"], TrackCodeInfoDictionary[track]["eventDateTime"], TrackCodeInfoDictionary[track]["itemWeight"], TrackCodeInfoDictionary[track]["groupedCompanyNames"] ); rtb_TrackInformation.Text = Text + Tracker_track24.getTrackJSON(tb_TrackCode.Text); }
public void track24dataToExcel() { Dictionary <string, Dictionary <string, string> > tmpDict = Tracker_track24.getTrackInfoDictionary(); ExcelWB.Sheets["Track24"].Activate(); ExcelWB.Sheets["Track24"].Select(); int i = 0; foreach (string key in tmpDict.Keys) { i++; ExcelWB.Sheets["Track24"].Cells[i + 1, 1].Value = (i).ToString(); ExcelWB.Sheets["Track24"].Cells[i + 1, 2].Value = key; ExcelWB.Sheets["Track24"].Cells[i + 1, 3].Value = tmpDict[key]["operationAttribute"]; ExcelWB.Sheets["Track24"].Cells[i + 1, 4].Value = tmpDict[key]["operationPlaceName"]; ExcelWB.Sheets["Track24"].Cells[i + 1, 5].Value = tmpDict[key]["eventDateTime"]; ExcelWB.Sheets["Track24"].Cells[i + 1, 6].Value = tmpDict[key]["itemWeight"]; ExcelWB.Sheets["Track24"].Cells[i + 1, 7].Value = tmpDict[key]["groupedCompanyNames"]; } ExcelApp.Visible = true; }
private void loadTrackListInfo(ExcelIO _excel) { Tracker_track24.getManyTrackInfo(_excel.LoadedTracks); _excel.track24dataToExcel(); }