title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
ASP.NET Core 6 : add multiple authentication schemes with multiple authorization policies along with dependency injection
<p>I need to create a framework for coworkers that allows for multiple authentication schemes and correlating authorization policies (since our IDP has multiple allowed approaches), but those schemes require dependency injection because the IDP information is provided from a cloud-based configuration source. The authen...
3
2,308
How can I receive this request in another server using curl and php
<p>I'm new here so please be patient, This is my request code, I want to write another piece of code in another server that will be accepting it and returning an xml 7101 success code using php and curl. How do I write code in a receiving server. This is actually API that I will be using to exchange data between my sy...
3
2,009
Android create file causing java.io.IOException
<p>I’m trying to implement a way to create pdf files in my app. Currently I’m using PDF Writer APW for that. I followed the <a href="https://stackoverflow.com/questions/25728927/how-to-add-android-pdf-writer-to-android-project">instruction from jguerinet</a> and pasted all necessary files to the project (as new package...
3
2,460
guide points polygon creation
<p>I am trying to help my users in the creation of a polygon, using circles in the vertices of said polygon. I know how to add the circles, but I do not see how to eliminate them at the end of the creation of the polygon with the double click, it always throws an error telling me that the object to be deleted is not de...
3
2,080
Smart_listing Gem sorting
<p>Im integrating <a href="https://github.com/Sology/smart_listing" rel="nofollow">Smart_listing</a> gem onto my Rails App. I have a <strong><em>Beer table</em></strong> in my database and a <strong><em>beer_type</em></strong> column. Right now im trying to set up a sorting function where Users can filter different typ...
3
1,328
Morgan printing alternate lines of log as blank
<p>I am trying to integrate Morgan with winston transports and winston-daily-rotate-file package. The reason why I am doing it is winston is used for some other logger and I am trying to use it for this as well.</p> <p>I am creating a stream for morgan like this in ExpressJS:</p> <pre><code>application.use(morgan(`${...
3
1,596
Portion of code (VBA) being skipped
<p>I have a custom application developed in and for MS Project. As it's executing one of its functions it's skipping over a portion of code resulting in an incorrect output. Below is the line of code causing the error and forcing the application to skip ahead. Anyone know what could be causing it?</p> <pre><code>Fil...
3
2,307
Library working only on >= android 5.0
<p>I know that asking for help in this case should not be completely right but I do not know what else to do.</p> <p>I'm using <a href="https://github.com/Omertron/api-thetvdb" rel="nofollow">this TVDB library</a> and when running on <strong>android >= 5.0</strong> everything works fine. If I run it in <strong>android...
3
1,608
nginx proxy only serves part of data Wordpress running on Ngninx
<p>I have a Wordpress instance running on first nginx server ( Virtual Machine A ) . I can work with perfectly fine locally, everythings is well resolved and all path are accessed ( like /wp-admin/ , /wp-content/ , /wp-includes/ etc... ) thru my url www.corph.mouradcloud.com</p> <p>As for now, I am not using SSL, so t...
3
1,631
Python-docx adding floating pictures
<p>Python-docx currently doesn't support inserting floating images, but I found the following code to be able to insert a &quot;behind text&quot; floating image, which works well.</p> <pre><code>from docx.oxml import parse_xml, register_element_cls from docx.oxml.ns import nsdecls from docx.oxml.shape import CT_Picture...
3
1,738
get the value of a row in ajax
<p>I am having problem getting the value of the row of my table using ajax and so far every time im getting its values its giving me nothing in return here is how i get it.</p> <h1>select.php</h1> <pre><code> while($row = mysqli_fetch_array($result)) { $output .= ' &lt;tr&gt; ...
3
1,129
How to get nightwatch test_workers work with browserstack-local
<p>I am trying to get Nightwatch's inbuilt parallel test_workers working with browserstack-local for local url testing. </p> <p>When running tests without browserstack local, Nightwatch test_workers seem to work just fine. The same is true for running local tests without test_workers enabled. </p> <p>I have tried the...
3
1,368
python can't see packages after update Mac OS X to 10.9.2
<p>Before update my mac configured once python. I don't know how configuration has been created. After update, python interpreter can't see old package. I am discover 3 directories: Firstly <strong>/Library/Python/2.7/site-packages/</strong> <a href="http://yadi.sk/d/GbD6sS7LMZ78Z" rel="nofollow">http://yadi.sk/d/GbD6...
3
1,155
How do we specify within a server environment which node.js start script to run?
<p>This may be a dumb question, but I'm stumped.</p> <p>I have 3 environments: Dev(local), Staging(remote) and Production(remote).</p> <p>I'm writing a relatively simply Express App.</p> <p>In my package.json file, I have specified start scripts for each of the 3 environments. Here's the full file:</p> <pre><code>{ &...
3
1,105
xamarin WKWebView, ipad does not support youtube full screen
<p>I implemented a webview using the WkWebview renderer.</p> <p>Fullscreen works fine on ipone. But it doesn't work on iPad.</p> <p>An image like the one below will appear.</p> <p><a href="https://i.stack.imgur.com/vSOvB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/vSOvB.png" alt="enter image desc...
3
1,444
bookmark / Favorite page using query firestore with flutter
<p>I want user to retrieve favorite by using query from firestore.</p> <p>My approach is to use Bool within firestore and then connect to</p> <pre><code>class Food { String id; String name; String category; String newcategory; String image; List subIngredients = []; Timestamp createdAt; Timestamp updat...
3
1,850
Using Python regular expressions to find and edit the contents of a text file
<p>I have a text file full of amino acids (CA-Final.txt) as well as some other data. Here is a snippet of the text file</p> <pre><code>ATOM 109 CA ASER A 48 10.832 19.066 -2.324 0.50 61.96 C ATOM 121 CA AALA A 49 12.327 22.569 -2.163 0.50 60.22 C ATOM 131 CA AGLN A...
3
1,073
I need to update some Label Text from outside of the function that created it
<p>I have a tkinter.Label created inside a function and from a totally seperate part of my code I need to update the text.</p> <p>I have tried just about every solution google provides over the last hour and I can't get any of them to work, some error, some show blanks, some just fail to do anything.</p> <p>I am crea...
3
1,079
Jquery function won´t work after XMLHttpRequest
<p>I have a div (#div_eventos) that is updated via XMLHttpRequest to update data cointained in it. Also I have a function that executes on keyup in a input text field. This function do hide or show table rows when find coincidences on the search field (input text). But after the div_eventos is updated the function does...
3
2,028
Trying to draw rectangles on click
<p>So I've been self teaching c# and following tutorials. Up until this time there was no major problems. Bun now i cant find solution on my own.</p> <p>So i got a listing of a simple form that's supposed to create rectangles and attractor points on different mouse clicks. But when I run the code, nothing happens.</p>...
3
1,492
Using Containable behavior to filter results in Cakephp 2.2.4
<p>I'm using containable behavior and the result of my find('all') is:</p> <pre><code>array( (int) 0 =&gt; array( 'User' =&gt; array( 'id' =&gt; '106', 'email' =&gt; 'daje@daje.it', 'pwd' =&gt; '0433c024cb08be13000d59a347e640482843f46f177e95749dc6599c259617fd3491dcb940b4...
3
1,411
Why do I get different output in Powershell from start-job vs just running the code?
<p>The script runs correctly when outside of Start-Job but when in a scriptblock I get incorrect results. Where am I going wrong?</p> <p>I need the Start-Job functionality since I have servers where the remote commands will hang (separate problem - WMI is borked) and I need to timeout and move to the next server.</p> ...
3
1,595
Python/Pandas: How do I combine two DataFrames, where one of the frames shall be a DataFrame within a cell of the other frame?
<p>I have two pandas DataFrames. Both DataFrames are time series with one common column (let's call it batchNumber) of the following structure:</p> <pre><code>[time = index, batchNumber, valueColumn, other fields] </code></pre> <p>The first DataFrame comprises one row per batchNumber, the second DataFrame comprises m...
3
1,252
How to get selected elements index of a gridview?
<p>Here, I am creating a dynamic gridview.</p> <pre class="lang-cs prettyprint-override"><code> private void PopulateImages() { ObservableCollection&lt;Attachment&gt; Images = new ObservableCollection&lt;Attachment&gt;(); Images.Add(new Attachment { Name = "Image 1", Inde...
3
1,911
Convert json format to another json format by AngularJS
<p>I'm trying to implement a questionnaire with angularjs,So I have the following response array ,I need to convert this object array to json format like the following output, So How can I convert object array to json format?</p> <pre><code> var response=[{"questiongroup":1,"question":1,"response":"response1"}, ...
3
2,090
Testing directive link in angular js
<p>I am testing following directive in angular Jasmine unit test </p> <pre><code>angular.module('components.privileges', []) .directive('hasPrivilege', function(privileges) { return { link: function (scope, element, attrs, $rootScope) { if (!angular.isString(attrs.hasPrivilege)) { throw "...
3
1,974
apoc.periodic.iterate fails when parallel = true
<pre><code>CALL apoc.periodic.iterate(&quot; CALL apoc.load.csv('/data/keywordOf.csv', {nullValues:['','na',false], sep:' '}) yield map as row &quot;, &quot;MATCH (h:keyword{nid: row._start}) MATCH (t:text{nid: row._end}) CALL apoc.merge.relationship(h, row._type, {}, {}, t, {}) yield rel RETURN rel&quot;, {batchS...
3
1,148
Extract data from XML document using t-sql
<p>I have been trying to extract data from the following xml doc using t-sql on sql server 2019.</p> <h2>XML:</h2> <pre><code>&lt;urlset xmlns=&quot;http://www.sitemaps.org/schemas/sitemap/0.9&quot; xmlns:image=&quot;http://www.google.com/schemas/sitemap-image/1.1&quot;&gt; &lt;url&gt; &lt;loc&gt;https://www.URL1...
3
1,176
MVC, .NET 5.0 - How to filter Index/Create pages based on database value?
<p>I am working on an ASP.NET Core MVC app using EF Core on .NET 5.0. I have configured my application's Startup.CS file to implement Azure AD Authentication per this documentation:</p> <p><a href="https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-v2-aspnet-core-webapp" rel="nofollow noreferrer...
3
1,117
.Net Api doesn't recognize my Controllers
<p>Guys i have a simple backend codes and i just wanted to integrate swagger ui but it only recognizes 3 Controller from 6 and 3 schema from 7 but when i try to make get request with postman it gives http 404 error. What did i do wrong? I'm using Win11 and .net 5 with Visual Studio 2019.</p> <p>startup.cs</p> <pre><cod...
3
2,534
OpMode stuck in stop() Android studio
<p>We are making a parking code for FTC Skystone where a color sensor is looking for a change in hue value to stop the robot. It works most times, but if we press the stop button, the code continues and errors out with an OpMode is stuck in stop(). </p> <p>Other than that, The sensor will only read it four out of five...
3
1,875
Background Script is not sending message to document script - Chrome Extension
<p>I am working with chrome extension and trying to send a message from background script to the content script. But I do not know why the message from background is not passing to the content script. </p> <blockquote> <p>First of all I check the cookies in the background script, if the cookies are available then it...
3
2,531
PHP find cheapest permutation
<p>I have multiple products that all have sizes and I need to find the cheapest configuration that meets the minimum required size.</p> <p>For example, John needs a minimum of 10 litres of storage - it can be more, but not less. </p> <p>There are 2L, 3L, 5L, 8L and 10L options (but this can change). </p> <p>As an ex...
3
1,823
Referencing bootstrap class in JQuery for ASP generated HTML
<p>My page uses ASP (VBScript) to generate a div with bootstrap class 'alert' upon successful SQL submission. What I want to happen is this - Once a user submits the form and the alert div appears, then they click on the first input field of the form, I want the alert div to disappear. I have a feeling the issue lies...
3
1,071
Passing a $_SESSION failed when creating the $_SESSION within Ajax function
<p>I have a simple registration form and the new comers will be registered with an ajax function. There I create a <code>$_SESSION['is_logged']</code> when the registration is finished. On var_dumb I get that the var is set. But when redirect on another page it is empty (I have included already the session_start() on t...
3
1,215
Verify JMH measurements of simple for/lambda comparisons
<p>I wanted to do some performance measurements and comparisons of simple for loops and equivalent streams implementations. I believe it's the case that streams will be somewhat slower than equivalent non-streams code, but I wanted to be sure I'm measuring the right things.</p> <p>I'm including my entire jmh class he...
3
3,104
dynamic force directed graph d3.js
<p>I am trying to create a dynamic d3.js force directed chart. I am creating some data with my generateData function and then updating this data each 3 seconds with updateData. </p> <p>The initial data displays well, but then the new node I am adding, are stacking on the top left of the SVG and the links completely di...
3
2,199
Sieve of erastothenes primality issue
<p>Set up to print out all false values which are prime numbers however out of 25 it prints. 3, 5, 7, 8, 9, 11, 13, 14, 15, 17, 19, 20, 21, 23, 24, not sure why some of them slip by. Any insight into the matter would be nice. </p> <p>Or simply pointing me in the write direction. Why are the non-prime numbers such as ...
3
1,216
setImageResource() not fetching the image through Firebase
<p>I am using a recyclerview for my firebase project. Initially upon clicking on the recyclerview card it would display complete information about the card. But it works fine till the cardview. Upon clicking the card it displays all the information except the image. Changed the names of the class here for better unders...
3
6,690
How to echo a value from another table inner joined with the current table
<p>I have a simple problem that I couldn't get my head around it the problem is I'm trying to echo a value from <strong>status</strong> table inner joined with the current table <em><code>user_asset</code></em> by status's id <em><code>s_id</code></em> </p> <p>I want to echo the name of the status but it keeps showin...
3
2,903
Undefined property: Fxp\Composer\AssetPlugin\Repository\AssetVcsRepository::$verbos
<p>Trying to install a simple repository using composer (composer require vimeo/vimeo-api ^2.0)</p> <p>And I can't seem to get it work.</p> <p>Here's the error</p> <pre><code>Installation failed, reverting ./composer.json to its original content. [ErrorException] ...
3
3,508
how to have 2 autocomplete in 2 different forms on same page bootstrap -3
<p>i have 2 tabs on home page and both have search forms with an autocomplete feature for input of location.</p> <p>html</p> <pre><code>&lt;div class="row"&gt; &lt;div class="col-md-4 scolleft"&gt; &lt;div class="bs-example bs-example-tabs cstyle04"&gt; &lt;ul...
3
2,447
Counting and Error Handling Block Guessing Game
<p>Could you, please, help me to understand how should I use try/except block and count tries at the same time. Here is the code without try/except block (it seems it's working fine):</p> <pre><code>import random number = random.randint(1, 10) tries = 3 name = input('Hi! What is your name?\n') answer = input(f'{name}...
3
1,144
Restrict the JPanel size issue
<p>Good Day-</p> <p>I'm working on <code>JApplets</code> in which I have two <code>tabbedPanel</code>. Now for the first <code>tabbed</code> I need to further divide the parent <code>JPanel</code> into two parts. For this I created two sub panels and also have used the <code>JSplitPane</code> class to split those into...
3
1,387
Unable to start activity ComponentInfo Error?
<p>I'm trying to duplicate the Android Game Services example "Type A Number Challenge" in my own game. It works fine until I log out and then back in, I get an the following error:</p> <pre><code>09-09 15:23:11.372: E/AndroidRuntime(7438): FATAL EXCEPTION: main 09-09 15:23:11.372: E/AndroidRuntime(7438): java.lang.Run...
3
1,951
Jetty 5.1.x start after 10 minutes or after "real local connexion"
<p>I work on a very old system : OSGi Framework with Jetty. Java command is launch inside a screen with -DmS parameters.</p> <p>At the end, console give me this :</p> <pre><code>osgi&gt; Sep 14, 2021 9:17:43 AM org.mortbay.http.HttpServer doStart INFO: Version Jetty/5.1.x Sep 14, 2021 9:28:32 AM org.mortbay.util.Contai...
3
1,821
I can't re-render app.js on login/logout from child component
<p>I can't find a solution on how to re-render app.js function. It's loaded first time, but when I click login or logout button I need to call a function from the helper again to check user status. App.js</p> <pre><code>import Routes from &quot;./Routes&quot;; import NavBar from &quot;./common/navBar&quot;; import { i...
3
1,380
How to put some of the values of a list inside a dictionary, using python?
<p>I have a list (see LIST) that I want to send to a dictionary.</p> <p>But I do not want to send all the data. Just some values (see SOME VALUES/FEATURES) which happen to repeat many times. For example, the word &quot;Model: xxx&quot; appears like 7 times. &quot;xxx&quot; is the name of the model and it will change.</...
3
2,655
All Laravel routes gives 404 on nginx subdirectory
<p>I have a problem with nginx configuration. I wanna have Laravel app in subdirectory, exactly domain.com/alfa. At domain.com is another app. And now all Laravel routes gives 404 on nginx subdirectory. Could someone help find an error?</p> <p>My paths:</p> <ul> <li>/var/www/ &lt;-- it's for domain.com</li> <li>/var...
3
1,098
Error: forEach undefined
<p>I'm having this forEach issue in my code, but I really don't know what is wrong, because for me it's right. I want to create a route where I can upload an Excel file and based on the file, the code validate the file and accept it or not.</p> <p>This is the code where forEach appears:</p> <pre><code>router.route('/...
3
1,044
Bootstrap navbar dropdown not working due to FlexStart css
<p>I know this is a very common issue; however, this one is peculiar. When I use just the regular CSS style sheets (so without style.css), everything works fine, but as soon as I input in main.css, the dropdown stops working. I have no idea which specific part of the CSS is throwing off the dropdown so I am asking for ...
3
5,990
Nestjs docker run Error: Cannot find module '/usr/src/app/dist/main'
<p>I built nest app and apply docker for deploy to server Nest app work as well in local dev environment I wrote <code>Dockerfile</code> by refer docker tutorial video/article</p> <p>Dockerfile code below :</p> <pre><code># Dockerfile From node:16 # Specify app directory WORKDIR /usr/src/app # Copy package.json and pa...
3
1,429
How to set the crs on a list of shapefiles (sf)?
<p>I am reading in a list of shapefiles (as <code>sf</code>) and I want to set the <code>crs</code>. I know this can easily be done for one shapefile (e.g., <a href="https://stackoverflow.com/questions/61590209/how-to-set-crs-for-a-shp-polygon-file-in-r">here</a>), but I have not found a solution for multiple or a list...
3
2,704
AsyncTask example using loop
<p>I'm implementing an example of AsyncTask and starting from the example here <a href="https://stackoverflow.com/questions/9671546/asynctask-android-example">AsyncTask Android example</a>.</p> <p>However, I want to make a change. In my GUI I want to put a text box where the user can type something and, every 10 secon...
3
2,192
Converting object datatype to datetime datatype in Python using pandas
<p>I have a dataset of Cab Fare Prediction and I need to convert one of its variable &quot;pickup_datetime&quot; to datetime datatype from object datatype. I am using pandas to convert it to datetime. Code:</p> <pre><code>data['pickup_datetime']=pd.to_datetime(data['pickup_datetime'],format='%Y-%m-%d %H:%M:%S UTC') </c...
3
1,469
Vertical to Horizontal Sub-Menus
<p>On my website at twoguysplayingzelda.com, my sub-menus (desktop view) are currently displayed vertically and I would like to change it to horizontal. When a user hovers over the tab "GAMES", I would like the sub-menu to stretch horizontally almost like a 2nd menu bar with all the games. My menu CSS code is as below....
3
2,324
Sails.js: error logging in with passport
<p>When this part of my code gets executed:</p> <pre><code>req.login(user, function (err){ if (err) return res.negotiate(err); return res.redirect('/welcome'); }); </code></pre> <p>I get the following error:</p> <pre><code>/home/oriol/Desktop/containers/node_modules/sails-mongo/node_modules/mongodb/lib/utils...
3
1,160
RenderScript Stopped Working in Android Lollilop
<p>I was developing an app in KitKat (4.4) and I recently flashed Lollipop on my device (5.1). My RenderScript Code seems that is has 'broken'. I mean it compiles fine, but when I launch the app it is not doing what it is supposed to do. I use it to do edge detection in parallel but it is not doing anything. Previously...
3
2,329
How to synchronize multiple threads from accessing some common data
<p>I have three different threads which creates three different objects to read/manipulate some data which is common for all the threads. Now, I need to ensure that we are giving an access only to one thread at a time.</p> <p>The example goes something like this.</p> <pre><code>public interface CommonData { public...
3
1,400
Simplifing a group of mouseover functions jquery
<p>Let me start by saying that this is working correctly, but I know it's not the most efficient way of coding it and I'm lacking the knowledge / understanding as to how to do this.</p> <p>For this specific problem, i have 8 different events that are using a mouseover / mouseout function where it is hiding other class...
3
1,336
Why does the N value increase to 2 and 3 in the printed output when the recursions of draw use n-1?
<p>I can't understand why the n value always becomes 1 after the if statement returns. Furthermore, I don't understand how the n value can increase if both recursions are using n-1. Can someone explain how these events happen? Comments are added in the output for further explanation of the question.</p> <pre><code>impo...
3
1,057
Swift Segment control with Table View Cell Data Passing techniques
<p>I want to pass the data from one table view cell to another one table view cell . I want to add those table view cell values to another segment control when user click the add the button . I have two table view with cell in same view controller . I am following delegate to implement it but I facing some issues .</p>...
3
2,677
First element of a repeating sequence in a pandas dataframe
<p>I want to keep only the value of the first instance of a sequence, following values to be set to zero. If the value repeats again later in the series, it should also be captured. e.g -265.95745849609375 is present at the top and at the bottom</p> <pre><code>* s1 Index value 847.724842779...
3
1,182
Elastic Query with `aggs` inside `must`
<p>Is there any way where we can <code>aggs</code> inside the inside the <code>must</code> .?? I have a query which hold multiple conditions and one aggregation, and aggregation must be part of <code>AND</code> clause (i mean <code>must</code>)</p> <p>query look something like this ...</p> <pre><code>{ &quot;query&qu...
3
4,001
Connect to google cloud instance fail
<p>I am trying to connect to google cloud instance from my ios app project. But I stuck in connecting to google cloud. Watched this tutorial but is outdated. <a href="https://www.youtube.com/watch?v=gxZvofAvgHQ&amp;t=179s" rel="nofollow noreferrer">https://www.youtube.com/watch?v=gxZvofAvgHQ&amp;t=179s</a></p> <p><str...
3
1,279
GraphicsContext strokeLine method does not draw onto the Canvas as expected
<p>When I use <code>GraphicsContext</code>'s <code>fillRect</code> method. aA rectangle is drawn on the Canvas <code>tilesetCanvas</code>. I then go on to use the <code>setStroke</code> and <code>strokeLine</code> methods, but these methods aren't updating the canvas like the <code>fillRect</code> method. Is there a sp...
3
5,233
JQ - Cannot extract values from Ubibot json
<p>I have a Ubibot ws-1 and I'm trying to extract Timestamp, Temperature, Humidity, Light and voltage from <code>last_values</code> in the following JSON</p> <p>The API JSON output is</p> <pre><code>{ "channel": { "channel_id": "1111", "name": "C-1111", "field1": "Temperature", "field2": "Humidity",...
3
1,153
Java documentlistener - program stop working after input
<p>Hi I have problem with my documentlistener. Program stop working after I insert value into textfield. This program should XOR 1st row of textfields with 2nd row of textfields and put result into 3rd row of textfields</p> <pre><code>package opa.beta1; import java.awt.BorderLayout; import java.math.BigInteger; impo...
3
1,893
Second argument in sort function gives typescript error - Object is possibly 'undefined'
<p>Second argument e.g <strong>b</strong> in sort function gives typescript error - Object is possibly 'undefined'. which I find it very weird as <strong>a</strong> is not, however they are the same type.</p> <pre><code>stories.value.sort((a, b) =&gt; a.story_score? - b.story_score?) </code></pre> <p>The whole context ...
3
1,262
t-sql recurrency procedure problem
<p>I have this code:</p> <pre><code>CREATE PROCEDURE AddTask @SessionID uniqueidentifier, @Login nvarchar(max), @Uni nvarchar(max), @Time datetime, @MaxOverviewTime int, @Date datetime, @DoTaskTime int, @Priority int, @TaskID int, @TaskWillBeDoIn datetime output AS BEGIN SET NOCOUNT ON; /*Algorytm 1. Pobranie wszystki...
3
4,096
for npm install from folder gives git error for wikimedia packages despite dependencies already being installed (shared hosting)
<p>Npm install on wikimedia packages (parsoid, restbase, plus service-runner and limitation) fails with a git error, despite having copied the source files in advance, and running </p> <p><code>npm install &lt;folder&gt;</code> or <code>npm install</code> from the actual folder, which has a package.json or</p> <p><co...
3
1,262
Django day and time picker
<p>I'm trying to build my first website with django,I've accomplished user registration and login so far but now I'm stuck: I want to show to the users a weekly calendar where they can pick a day and book a gym class. I tried to handle every week day like a form field but it didn't work. </p> <p>Any advice on how I s...
3
6,337
To draw rectangles inside label using Qpainter in python
<p>I am trying to draw rectangles according to a percentage value inside my labels. So it is important for me to know the exact coordinates of my labels. Since I am using multiple windows in cascade, the global positions of the current window are not retrieved accurately. Is there an easy workaround to this problem wit...
3
1,094
Specialized Cell.init(coder:) Crash
<p>Im receiving a crash <code>&lt;compiler-generated&gt; line 0 specialized MessagesCell.init(coder:)</code> over Firebase, this crash is being received only on iOS 9.2.x or 9, i have tried to trace it and understand what is exactly happening but on the simulator its not happening at all.</p> <p>Here is the way i regi...
3
3,636
creating one array out of multiple arrays and concatenating unique values in a certain key
<p>I need to loop through a bunch of arrays that I am getting back from mysql that contain a lot of duplicate entries and create one array out of several. The arrays will have one or more unique values in them so I need to keep these but some how concatenate them together into one string using commas or semicolons. So ...
3
1,527
Exception when add data into TableViewer
<p>I have 2 TableViewer controls in a composite (Supposed they are : <strong>viewer1</strong>, <strong>viewer2</strong>). When initialize application, one "<strong>viewer1</strong>" is filled data from server while "<strong>viewer2</strong>" is set null.</p> <pre><code>viewer1.setInput(getData()); viewer2.setInput(nul...
3
1,899
PowerShell New-Item output is inconsistent - Why?
<p>I am getting different out for the same powershell command and I am not sure why.</p> <p>When this runs within a function, I get output 1 and when I run by itself I get output2</p> <pre><code>New-Item -Path C:\DEPL\nichdwww\deployments\Full\bob3 -type directory </code></pre> <p><strong>Output 1</strong></p> <pre...
3
1,675
How to use setInterval inside useEffect to update the state?
<p>I'm pretty new to javascript, and I have never used <code>setInterval()</code> before. I am trying to make an automatic slide show. Currently, my slideshow will run once and then stop. How do I get it to continually run? I would really appreciate any help or advice on how to get this to work. Thank you!</p> <p>Code ...
3
1,704
Can't find variable: NativeEventEmitter in react native while using the @philly25/react-native-paytm package
<p><strong>How to integrate paytm payment gateway in react native android app</strong></p> <p>i am using the @philly25/react-native-paytm package sample code for testing but getting error Can't find variable: NativeEventEmitter how to integrate paytm payment gateway with react native . and using this samples code :-<...
3
3,795
Beam: AfterProcessingTime cause 'NoneType' object has no attribute 'time'
<p>With the following codes under beam <code>2.14.0</code></p> <pre class="lang-py prettyprint-override"><code>| "FixedWindow" &gt;&gt; beam.WindowInto(beam.window.FixedWindows(4 * 60), trigger=beam.trigger.Repeatedly( beam.trigger.AfterProcessingTime(delay=1 * 60) ...
3
1,422
org.hibernate.MappingException: Could not determine type for: java.util.Comparator
<p>I am having a problem in mapping jpa, please if anyone has more experience in using jpa and could help me.</p> <p>I have ran some searches in the internet, But nothings works for me.</p> <p>I hope i ll get some fix!!</p> <p>Thanks!</p> <p>Here my Code:</p> <p>Metodologia.java</p> <pre><code>@Entity @Table(name...
3
1,120
CSS not working on menu for responsive design
<p>I have made a pretty rough menu for responsive web, everything seems working fine. But when I open on devices like iPad and phones, I found a little bug which I am unable to solve. I did used jQuery for that. What I am trying to do is when the menu is opened in devices, it should get close soon after the option is c...
3
3,011
How do I put my content in the right place and for all my pages?
<p>I need help for something please. I'm working on my structure, but I've some problems...</p> <p>I created a page called "page-container.php" and the content is:</p> <pre><code>&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;meta charset="UTF-8"&gt; &lt;title&gt;&lt;?= $page_title; ?&gt;&lt;...
3
1,147
generalise where clause in linq query
<p>I have the following linq query:</p> <pre><code> var fileDocuments = ( from doc in fileUploads from invoice in ( from inv in _dbContext.SupplierInvoiceHeaders where inv.InvoiceDocumentId == doc.ID || inv.JobSheetInvoiceId == doc.ID selec...
3
1,645
Manipulate child elements with xPath in PHP
<p>I have a XML document with an element (named <code>region</code>) that may or may not have multiple child elements. For my import i need to make sure that there is only one child element. If there are more child elements, i need to remove all children, except the last one. The following situations can occur:</p> <p...
3
1,028
Using g++ 4.6.1 I get many C++ compile errors when trying to include xaudio2.h
<p>I have a c++ Windows app that compiles fine using Visual Studio 2010. I also wanted to have the ability to compile it using MinGW (on a Windows7-64 PC). When g++ processes the xaudio2.h header file I get the errors listed below. Does anyone know of a fix aside from manually hacking the include file.</p> <pre><code>...
3
1,666
Selenium Python nested dropdowns
<p>So I'm trying to test a nested dropdown with Selenium Python using the conditional statements like so: <a href="https://i.stack.imgur.com/rh06w.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/rh06w.png" alt="enter image description here" /></a></p> <pre><code>if d_Biz == 'Marketing': ...
3
3,390
VHDL Confusion using concurrent code and sequential code
<p>I am trying to code a 8 bit full adder using just concurrent code in VHDL but I got an error in the syntaxis. In the first instance i did this:</p> <pre><code> LIBRARY ieee; USE ieee.std_logic_1164.ALL; ENTITY concfulladder IS PORT( A: IN std_logic_vector (7 DOWNTO 0); B: I...
3
1,772
jq: avoid nested array mapping
<p>Here's my document:</p> <pre class="lang-json prettyprint-override"><code>{ &quot;_id&quot;: &quot;a6c8004c-efdc-4462-b474-31df2d417be3&quot;, &quot;address&quot;: [ { &quot;city&quot;: { &quot;value&quot;: &quot;2505300&quot; }, &quot;state&quot;: { &quot;value&quot;: &quot...
3
1,110
AWS ElasticBeanstalk failed to deploy Django/Postgres app
<p>I'm having a hard time deploying my app built with Django, Postgres, DjangoQ, Redis and ES on AWS Elastic Beanstalk, using docker-compose.yml.</p> <p>I've used EB CLI (eb init, eb create) to do it and it shows the environment is successfully launched but I still have the following problem.</p> <ol> <li><p>On the EC2...
3
1,204
SQL statement to populate more than one listbox at a time
<p>I'm trying to allow a user to specify how many rows they would like to add to the order form for the customer's purchase. This allows the user to have as many rows as needed for purchasing products rather than having a set list. I have the functionality working properly, where if you type in 3 and submit, it will gi...
3
5,533
How to set focus of input after computed has been updated
<p>I have table/grid that shows devices based on their type. Whenever the dropdown changes, the table should update to show the correct devices. To do this i have a computed that filters the devices by type and adds a new blank row to the table/grid.</p> <p>Here's the html: </p> <pre><code>&lt;table&gt; &lt;t...
3
1,182
PUB-SUB network with proxy: How to improve number of frames per second
<p>Beginner in ZMQ. I implemented a PUB-SUB network with a proxy, with the idea to plug multiple websockets as PUBs into my proxy, into an aggregated feed (the SUB). I used the inproc protocol as it is all happening on the same process. </p> <p>I wrote the below. I obtain 400 to 500 FPS. This is way too slow. </p...
3
1,054
efficient way of accessing opencv Mat elements
<p>I'm trying to play around with some OpenCV and thought up an interesting little scenario to work on.</p> <p>Basically, I want to take a pixel, add the colour values from the 3 neighbouring pixels (so (x, y), (x+1, y) (x, y+1) and (x+1, y+1)) and divide the result by 4 to get an average colour value. Then the next s...
3
1,656
Python sqlalchemy error when creating the table
<p>I'm trying to get a <code>.csv</code> file, filter some columns and create a new MySQL table with the new filtered df.</p> <p>The issue is that I have one particular value within that <code>.csv</code> with a different char set, as you can see below (<code>'\ufeffY'</code>):</p> <pre><code>df['Supported'].unique() ...
3
1,262
Not processing multiplication inside the class
<p>How can I fix the multiplication error? The formula is inside the nested class Area1 and I can't get the total value or product given by the user</p> <p>I've tried giving it a value like:</p> <p>side1 = 0;</p> <p>or</p> <p>side1 = 1;</p> <p>The answer is always equal to 0</p> <pre><code>public void getArea(){ in...
3
1,148
Active modal view codeigniter
<p>Hy, I want to edit some data using modal view. So I make the code for modal view and I am unable to edit input area.</p> <p><img src="https://i.stack.imgur.com/3QiXw.jpg" alt="You can see the image with issue here."></p> <p>The code for my modal is:</p> <pre class="lang-html prettyprint-override"><code>&lt;?php ...
3
1,162
Keras word2vec model - average word vectors - best approach
<p>I have followed the word2vec tutorial using keras in R <a href="https://blogs.rstudio.com/tensorflow/posts/2017-12-22-word-embeddings-with-keras/" rel="nofollow noreferrer">here</a> and I have managed to obtain word embeddings for each word. I would like to now pass my word embeddings to each <code>document</code> a...
3
2,603
Select-String -pattern not taking variable
<p>I am trying to use a variable in <code>select-string -pattern</code> but it returns nothing. If I copy and paste the contents of the variable into the syntax, it works. </p> <p>What I have is a few hashes that I previously recorded and want to get the hashes of the same directory again and see if they are the same ...
3
2,161
Remove word proofing errors from WordML
<p>I have the same problem as <a href="https://stackoverflow.com/questions/939898/remove-word-proofing-errors-from-wordml-and-merge-the-nodes">Remove word proofing errors from WordML and merge the nodes</a> -- to which @Rupesh_Kr provided a suggested xsl template. How do I use it (insufficient reputation to ask there)?...
3
3,049