Tutorial by Examples

This example illustrates a concept to perform reduction or gathering using std::vector and OpenMP. Supposed we have a scenario where we want multiple threads to help us generate a bunch of stuff, int is used here for simplicity and can be replaced with other data types. This is particularly useful...
//create a new ExcelPackage using (ExcelPackage excelPackage = new ExcelPackage()) { //create a datatable DataTable dataTable = new DataTable(); //add three colums to the datatable dataTable.Columns.Add("ID", typeof(int)); dataTable.Columns.Add("Type"...
//create a new ExcelPackage using (ExcelPackage excelPackage = new ExcelPackage()) { //the query or stored procedure name for the database string sqlQuery = "SELECT * FROM myTable"; //create a datatable DataTable dataTable = loadExternalDataSet(sqlQuery); //c...
Fill some cells with text. worksheet.Cells["A1"].Value = "Lorem ipsum"; worksheet.Cells["B2"].Value = "dolor sit amet"; worksheet.Cells["C3"].Value = "consectetur adipiscing"; worksheet.Cells["D4"].Value = "elit sed do ei...
//create a new ExcelPackage using (ExcelPackage excelPackage = new ExcelPackage()) { //create a WorkSheet ExcelWorksheet worksheet = excelPackage.Workbook.Worksheets.Add("Sheet 1"); //create a new list with books List<Book> books = new List<Book>(); ...
used to get request information such as parameter, header information, remote address, server name, server port, content type, character encoding. Index.html <form action="req.jsp"> <input type="text" name="username"> <input type="s...
Install WebServer Role Install WebDeploy 3.6 from MSDN Activate ASP.NET 4.6 under Web Server (IIS) > Web Server > Application Development
Good video tutorials about Emacs can be found at emacsrocks.com.
If you are using JUnit to execute, you can extend the TestWatcher class: public class TestRules extends TestWatcher { @Override protected void failed(Throwable e, Description description) { // This will be called whenever a test fails. } So in your test class you can si...
Using the EventFiringWebDriver. You can attach WebDriverEventListener to it and override methodes, ie the onException method: EventFiringWebDriver driver = new EventFiringWebDriver(new FirefoxDriver()); WebDriverEventListener listener = new AbstractWebDriverEventListener() { @Override pu...
//set the total value of cells in range A1 - A25 into A27 worksheet.Cells["A27"].Formula = "=SUM(A1:A25)"; //set the number of cells with content in range C1 - C25 into C27 worksheet.Cells["C27"].Formula = "=COUNT(C1:C25)"; //fill column K with the s...
//set the total value of all cells in Sheet 2 into G27 worksheet.Cells["G27"].Formula = "=SUM('" + worksheet2.Name + "'!" + worksheet2.Dimension.Start.Address + ":" + worksheet2.Dimension.End.Address + ")"; //set the number of cells with conten...
If you use formulas, Excel will ask you to save the file every time, even if there were no changes made. To prevent this behaviour you can set the calculation mode to manual. excelPackage.Workbook.CalcMode = ExcelCalcMode.Manual; //fill the sheet with data and set the formulas excelPackage....
//create a new ExcelPackage using (ExcelPackage excelPackage = new ExcelPackage()) { //create 2 WorkSheets ExcelWorksheet worksheet = excelPackage.Workbook.Worksheets.Add("Sheet 1"); ExcelWorksheet worksheet2 = excelPackage.Workbook.Worksheets.Add("Sheet 2"); ...
Using private repos working with yarn caveat: This works using npm: "common-js": "[email protected]:<user-name>/<repo-name>.git#<identifier>" but will not work using yarn. This change is required: "common-js": "git+ssh://[email protected]:&...
Add this lane to your Fastfile and run fastlane installAll type:{BUILD_TYPE} in command line. Replace BUILD_TYPE with the build type you want to build. For example: fastlane installAll type:Debug This command will build all flavors of given type and install it to your device. Currently, it doesn't...
A vector is essentially a pointer to a heap-allocated, dynamically-sized list of objects of a single type. Example fn main() { // Create a mutable empty vector let mut vector = Vec::new(); vector.push(20); vector.insert(0, 10); // insert at the beginning println!(&qu...
Slices are views into a list of objects, and have type [T], indicating a slice of objects with type T. A slice is an unsized type, and therefore can only be used behind a pointer. (String world analogy: str, called string slice, is also unsized.) Arrays get coerced into slices, and vectors can be...
Code below will show you bootstrap model without writing hole long code by generating bootstrap model at run time. It will also make creating multiple bootstrap model i.e. one on other easy. Follow below simple code to make simple bootstrap model. Include below CSS to your code <link rel=&quot...
Include below CSS to your code <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap3-dialog/1.34.7/css/bootstrap-dialog.min.css&...

Page 1062 of 1336