View gist:3411016
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
Sub ActiveReport_DataInitialize | |
rpt.fields.add("rptDate") | |
rpt.fields.add("rptTitle") | |
rpt.fields.add("header1") | |
rpt.fields.add("statedesc") | |
rpt.fields.add("cuname") | |
rpt.fields.add("camel") | |
rpt.fields.add("asinum") | |
rpt.fields.add("yearendshares") | |
rpt.fields.add("depositrequired") |
View gist:3411094
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
Dim rowsCounter As Integer = 0 | |
Dim dr as DataRow | |
Sub ActiveReport_FetchData(eof) | |
rpt.fields("rptDate").value = Now() | |
rpt.fields("rptTitle").value = "FOR " & asOfDate & " USING " & camel & " CAMEL SCORE" | |
'rpt.fields("header1").value = dataclass.GetParm("year") & " DEPOSIT" | |
rpt.fields("header1").value = "DEPOSIT" | |
If rowsCounter < ds.Tables(0).Rows.Count Then | |
eof = false | |
dr = ds.Tables(0).Rows.Item(rowsCounter) |
View gist:3415320
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
SELECT Movie.MovieID, Movie.Title, Movie.Length, Movie.YearReleased, Movie.UserRating, Movie.MPAA, MoviePerson.MoviePersonID, MoviePerson.FirstName+" "+MoviePerson.LastName AS CastName, CrewTitle.CrewTitleID, CrewTitle.Title AS CrewTitle, Genre.GenreID, Genre.GenreName | |
FROM CrewTitle INNER JOIN ((Genre INNER JOIN (Movie INNER JOIN MovieGenres ON Movie.MovieID = MovieGenres.MovieID) ON Genre.GenreID = MovieGenres.GenreID) INNER JOIN (MoviePerson INNER JOIN MovieCrew ON MoviePerson.MoviePersonID = MovieCrew.CastID) ON Movie.MovieID = MovieCrew.MovieID) ON CrewTitle.CrewTitleID = MovieCrew.TitleID | |
WHERE (((Movie.MovieID)=[?])) | |
ORDER BY Movie.MovieID, MoviePerson.MoviePersonID, CrewTitle.CrewTitleID, Genre.GenreID; |
View gist:3850474
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
var navigationBar = viewer1.Toolbar.NavigationBar; | |
navigationBar.Visible = false; | |
var items = navigationBar.Items.Cast<ToolStripItem>().ToList(); | |
viewer1.Toolbar.MainBar.Items.AddRange(items.ToArray()); |
View gist:3896819
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
private void view_Click(object sender, EventArgs e) | |
{ | |
var rpt = (GrapeCity.ActiveReports.PageReport)designer1.Report; | |
rpt.ConfigurationProvider = new DefaultConfigurationProvider(); | |
var pageDocument = new GrapeCity.ActiveReports.Document.PageDocument(rpt); | |
this.viewer1.LoadDocument(pageDocument); | |
} |
View gist:3909467
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
private void Form1_Load(object sender, EventArgs e) | |
{ | |
var rpt = new PageReport(new FileInfo("report.rdlx")); | |
var doc = new PageDocument(rpt); | |
var xml = new XmlRenderingExtension(); | |
var settings = new Settings {Encoding = "UTF-8"}; | |
var streamProvider = new CustomStreamProvider(new DirectoryInfo("."), "report.xml"); | |
doc.Render(xml, streamProvider, settings); | |
} |
View DisksMoveSolution.cs
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 Solution | |
{ | |
private static IEnumerable<string> ReadInputLine() | |
{ | |
var input = Console.ReadLine(); | |
return input == null ? null : input.Split(' '); | |
} | |
private delegate bool Parse<T>(string str, out T result); | |
View gist:4950514
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
private void SelectAllClickHandler(object sender, EventArgs agrs) | |
{ | |
designer1.ExecuteAction(DesignerAction.SelectAll); | |
} | |
private void DesignerForm_Load(object sender, EventArgs e) | |
{ | |
View gist:5088530
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
PageReport pagereport = new PageReport(new System.IO.FileInfo("Invoice2.rdlx")); | |
pagedoc = new PageDocument(pagereport); | |
pagedoc.LocateDataSource += new LocateDataSourceEventHandler(runtime_LocateDataSource); | |
pagedoc.PageReport.Document.LocateDataSource += new LocateDataSourceEventHandler(runtime_LocateDataSource); | |
pagedoc.Print(); |
View gist:5351370
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
private void DisableChartWizard() | |
{ | |
var regSubkey = Microsoft.Win32.Registry.CurrentUser.CreateSubKey(@"SOFTWARE\GrapeCity\ActiveReports 6\Windows"); | |
if (regSubkey!=null) | |
{ | |
regSubkey.SetValue("AutoRunWizard", 0); | |
} | |
} |
OlderNewer