ClosedXML find last row number
I'm using ClosedXML with C# to modify an Excel workbook. I need to find the last row number used but `.RowCount()` counts how many rows are in the worksheet. So it is returning 1 million rows when t...
- Modified
- 1 Dec at 07:48
Servicestack 4.5.6 broke HasRole and HasPermission
I lost a breaking change somewhere - I upgraded ServiceStack from a pretty old version today (4.0.x) and found the new parameter of type IAuthRepository on HasRole and HasPermission. My project doesn'...
- Modified
- 31 Jan at 18:16
Mapper not initialized, When Use ProjectTo()
I Use In My Project. When I Use `ProjectTo()` In Code Get This Error: > Mapper not initialized. Call Initialize with Appropriate configuration. If you are trying to use mapper instances through a co...
- Modified
- 23 May at 12:25
How do I delete multiple rows in Entity Framework Core?
I need to delete multiple rows from a database using Entity Framework Core. This code does NOT work: ``` foreach (var item in items) { myCollection.Remove(item); } ``` because I get an error "...
- Modified
- 17 Sep at 16:20
How to unit test DBService which uses the Servicestack Funq IOC
I am new to a project which I should extend so I decided to use TDD to quickly recognize any problems of a system I do not fully understand. There is one class called `DBService` which "encapsulates...
- Modified
- 31 Jan at 15:0
BindingSource - what are the advantages of using BindingSource
What gives me using something like this: ``` DataGridView dgvDocuments = new DataGridView(); BindingSource bindingSource = new BindingSource(); DataTable dtDocuments; dtDocuments = MsSQL.GetDocument...
- Modified
- 31 Jan at 12:37
Could not initialize plugin: interface org.mockito.plugins.MockMaker
I'm getting following exception once tests is started: ``` Testcase: treeCtorArgumentTest(com.xythos.client.drive.cachedtree.CachedTreeTest): Caused an ERROR Could not initialize plugin: interface o...
- Modified
- 31 Jan at 12:27
How to create multiple page app using react
I have created a single page web app using react js. I have used `webpack` to create bundle of all components. But now I want to create many other pages. Most of pages are API call related. i.e. in th...
- Modified
- 31 Jan at 11:31
Set height of chart in Chart.js
I want to draw a horizontal bar chart with Chart.js but it keeps scaling the chart instead of using the height I assign the canvas form the script. Is there any way to set the height of the graph from...
- Modified
- 29 Aug at 17:7
Using async/await or task in web api controller (.net core)
I have a .net core API which has a controller that builds an aggregated object to return. the object it creates is made of data that comes from 3 method calls to a service class. These are all indepen...
- Modified
- 31 Jan at 10:46
Conditional predicates in LINQ?
Is there a way to combine the queries in `if` and `else` sections? ``` public List<MyClass> GetData(Category category, bool flag= true) { IQueryable<MyClass> result; if (flag) { ...
- Modified
- 31 Jan at 08:34
Kendo UI datepicker incompatible with Chrome 56
After updating Chrome to version 56.0.2924.76 (64-bit), our Kendo datepickers stopped working. All datepickers were bound using ViewModels, and now they don't show their values. If we inspect them we ...
- Modified
- 18 Apr at 15:44
'this' implicitly has type 'any' because it does not have a type annotation
When I enable `noImplicitThis` in `tsconfig.json`, I get this error for the following code: > ``` 'this' implicitly has type 'any' because it does not have a type annotation. ``` ``` class Foo impl...
- Modified
- 31 Jan at 04:1
Load Connection String from Config File in Azure Functions
In my Azure Function I am using a Library which establishes a connection to an SQL server via the ConnectionString from the ConfigurationManager like this: ``` var cs = System.Configuration.Configura...
- Modified
- 31 Jan at 12:40
How to use zIndex in react-native
I've want to achieve the following: [](https://i.stack.imgur.com/QUe7dm.png) The following images are what I can do right now, but that's NOT what I want. [](https://i.stack.imgur.com/P7ASMm.png)[](...
- Modified
- 29 Mar at 11:26
How can I get the arguments called in jest mock function?
How can I get the arguments called in jest mock function? I want to inspect the object that is passed as argument.
- Modified
- 13 Oct at 19:1
How to download files using axios
I am using axios for basic http requests like GET and POST, and it works well. Now I need to be able to download Excel files too. Is this possible with axios? If so does anyone have some sample code? ...
- Modified
- 10 Jan at 19:24
How int + string becomes string?
I came across a strange way to implement `ToString()` and I am wondering how it works: ``` public string tostr(int n) { string s = ""; foreach (char c in n-- + "") { //<------HOW IS THIS PO...
- Modified
- 9 Jul at 13:10
Understanding "VOLUME" instruction in DockerFile
Below is the content of my "Dockerfile" ``` FROM node:boron # Create app directory RUN mkdir -p /usr/src/app # Change working dir to /usr/src/app WORKDIR /usr/src/app VOLUME . /usr/src/app RUN npm...
- Modified
- 16 Sep at 20:23
How to join 3 tables with linq
I am trying to join 3 tables in a query with Linq to get data from all 3 tables. Below is an image of the table schemes: [](https://i.stack.imgur.com/LXSCX.jpg) The query should select: SewagePlantN...
- Modified
- 8 Feb at 22:1
Tuple vs string as a Dictionary key in C#
I have a cache that I implement using a ConcurrentDictionary, The data that I need to keep depends on 5 parameters. So the Method to get it from the cache is: (I show only 3 parameters here for simpli...
- Modified
- 2 Feb at 12:22
VS Designer error: GenericArguments[0], 'X' on 'Y' violates the constraint of type parameter 'Z'
I am trying to create forms that inherit from a "generic" base class where the generic argument of that base class has a constraint that it must implement one of my interfaces. It compiles and runs j...
- Modified
- 30 Jan at 08:49
.Net MySql error "The given key was not present in the dictionary"
Trying to get simple count from table results in exception bellow. Tried different select statemens which also makes exception: "`SELECT * FROM goods`", but "`SELECT col1, col2 FROM goods`" - works wi...
<div> cannot appear as a descendant of <p>
I'm seeing this. It's not a mystery what it is complaining about: ``` Warning: validateDOMnesting(...): <div> cannot appear as a descendant of <p>. See ... SomeComponent > p > ... > SomeOtherComponen...
- Modified
- 6 Dec at 16:52
LogisticRegression: Unknown label type: 'continuous' using sklearn in python
I have the following code to test some of most popular ML algorithms of sklearn python library: ``` import numpy as np from sklearn import metrics, svm from sklearn.linear_mode...
- Modified
- 29 Jan at 22:7