question_id int64 37.6M 73.2M | input_text stringlengths 88 52.4k | output_text stringlengths 37 35.6k | title stringlengths 15 150 | tags stringlengths 1 107 | q_score int64 -19 397 | view_count int64 3 879k | answer_count int64 1 21 | accepted_answer_id int64 37.6M 73.8M | answer_id int64 37.6M 73.8M | a_score int64 -5 1.29k | is_accepted bool 1
class | creation_date stringlengths 20 24 | input_text_instruct stringlengths 251 52.6k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
72,220,546 | how to do flutter-channel to javascript code?<p>How can we interact with JavaScript code in the Flutter (Via flutter -channel) and add new tags to the project html page? (for example counter app show each number as one tag < div > on html)</p> | <p>I write answer in <a href="https://medium.com/@software8686/how-to-work-js-file-in-flutter-web-80e7bd5912ca" rel="nofollow noreferrer">this article</a> on medium.
Need platform channel for create connection between JavaScript code and call in on the ui .</p> | how to do flutter-channel to javascript code? | flutter | 0 | 33 | 1 | 72,250,774 | 72,250,774 | 0 | true | 2022-05-12T18:33:09.897Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to do flutter-channel to javascript code?<p>How can we interact with JavaScript code in the Flutter (Via flutter -channel) and add new tags to the projec... |
72,210,322 | How to get totalCount of elements where id matches parentId<p>I have following structure:</p>
<pre><code>const arr = [
{ id: 1, count: 0, parentId: null },
{ id: 2, count: 30, parentId: 1 },
{ id: 3, count: 1, parentId: 2 }
];
</code></pre>
<p>and I want to get this result</p>
<pre><code>const res = [
{ id: 1, ... | <p>Yu need to iterate over the array, filter out the items that have the matching the parent id and sum the counts using reduce() and add that to the existing count on each item.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="s... | How to get totalCount of elements where id matches parentId | javascript|arrays | 0 | 32 | 2 | 72,210,462 | 72,210,462 | 0 | true | 2022-05-12T05:00:08.523Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to get totalCount of elements where id matches parentId<p>I have following structure:</p>
<pre><code>const arr = [
{ id: 1, count: 0, parentId: null },... |
72,173,216 | Convert epoch duration (few days) in ms to time<p>I am trying to convert duration in ms to human-readable format. It works fine if it is below 24 hours, but once it crosses that value it starts again from 0. Is it possible to keep the hours once it crosses the day limit?</p>
<p>My current code implementation (in Postgr... | <p>As a_horse_with_no_name commented, the data type <code>time</code> represents a "point in time" rather than a duration. So 70h can not be represented as a <code>time</code> value (the largest time value is <code>24:00:00</code>). You probably want to convert it to an <code>interval</code> instead:</p>
<pre... | Convert epoch duration (few days) in ms to time | sql|postgresql | 0 | 24 | 1 | 72,174,516 | 72,174,516 | 0 | true | 2022-05-09T13:59:00.237Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Convert epoch duration (few days) in ms to time<p>I am trying to convert duration in ms to human-readable format. It works fine if it is below 24 hours, but ... |
72,210,576 | JavaScript alert recognizing as same line and showing alert<p><a href="https://i.stack.imgur.com/mY8Mr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/mY8Mr.png" alt="enter image description here" /></a>In website, I made this. When I press enter, it recognize as new barcode in textarea.
In JavaScrip... | <pre><code>var barcodenoStr = $('#barcodeno').val().trim();
let barcodes = barcodeStr.split("\n");
let allBarcodeValid = true;
let barcodeno_array = []
for(let i =0; i < barcodes.length; i++){
let barcodeno = barcodes[i];
if (barcodeno == "" || barcodeno.length != 6){
allBarcodeValid = fa... | JavaScript alert recognizing as same line and showing alert | javascript|html | 0 | 54 | 1 | 72,211,185 | 72,211,185 | 0 | true | 2022-05-12T05:39:28.643Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
JavaScript alert recognizing as same line and showing alert<p><a href="https://i.stack.imgur.com/mY8Mr.png" rel="nofollow noreferrer"><img src="https://i.sta... |
72,141,849 | Split 600 columns into 2 new columns for each one, with old and new column names in vectors<p>I want to split 600 columns (listed in a vector) at a delimiter (in this case a <code>/</code>) into 2 new columns for each one (also listed as vectors). I've worked out basic logic for the split as shown below, but is there a... | <p>You can do this:</p>
<pre><code>separate(
df1 %>% pivot_longer(everything()),
value, into=c("left", "right"), sep = "/"
) %>%
pivot_wider(names_from="name", values_from = left:right, values_fn = list,names_sep = "") %>%
unnest(everything()) %>%
... | Split 600 columns into 2 new columns for each one, with old and new column names in vectors | r|string|dataframe|vector|multiple-columns | 0 | 32 | 2 | 72,142,103 | 72,142,103 | 0 | true | 2022-05-06T12:58:30.733Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Split 600 columns into 2 new columns for each one, with old and new column names in vectors<p>I want to split 600 columns (listed in a vector) at a delimiter... |
72,224,574 | Disable this console messages that appears in event handlers at React<p>How to disable these console messages when doing an event handler (like onChange) in react. It comes to this file called ContentScript.js but I don't know how to remove it. It's annoying and it sometimes makes me confused about the console.log mess... | <p>You can use -</p>
<pre><code>console.clear()
</code></pre>
<p>before calling your debug <code>console.log()</code></p>
<p>It will clear your previous console messages.</p>
<p>Another workaround:</p>
<p>ContentScript.js is coming from your browser extension if it doesn't exist in your project. Disable all browser ext... | Disable this console messages that appears in event handlers at React | reactjs|onchange | 0 | 162 | 1 | 72,224,614 | 72,224,614 | 0 | true | 2022-05-13T04:46:34.993Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Disable this console messages that appears in event handlers at React<p>How to disable these console messages when doing an event handler (like onChange) in ... |
72,144,124 | How to group and Throttle Object by ID Rx<p>I have incoming objects of the same type, but if An Object property <code>IsThrottlable</code> is set to false regardless of the ID I DON'T want to throttle it but if <code>IsThrottlable</code> is set to true I would like to throttle the object every 3 seconds by ID. So if an... | <p>One way to do it is to group the sequence by the <code>IsThrottlable</code> property. This way you'll get a nested sequence that contains two subsequences, one containing the throttleable elements and one containing the non-throttleable elements. You can then transform each of the two subsequences accordingly, and f... | How to group and Throttle Object by ID Rx | c#|system.reactive | 0 | 127 | 2 | 72,144,504 | 72,144,504 | 0 | true | 2022-05-06T15:40:06.240Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to group and Throttle Object by ID Rx<p>I have incoming objects of the same type, but if An Object property <code>IsThrottlable</code> is set to false re... |
72,210,373 | Nginx cofig can't read the static with 404 ERR_ABORTED<ul>
<li>system: ubuntu 18.04.5 LTS</li>
<li>nginx: nginx/1.14.0 (Ubuntu)</li>
</ul>
<p>Hi, I am trying Nginx to proxy reverse a service(doccano) to my prod path and need some help, below is the config file</p>
<pre><code>log_format main_ext '$remote_addr - $remote... | <p>I have solved the problem.
Since the service of <a href="https://github.com/doccano/doccano" rel="nofollow noreferrer">doccano</a> I used is deployed by docker-compose, and the static files are bind in the <code>docker_nginx_1</code> container inside the <strong>doccano</strong> project.
Just modify my production ng... | Nginx cofig can't read the static with 404 ERR_ABORTED | nginx|nginx-reverse-proxy|doccano | 0 | 85 | 1 | 72,257,250 | 72,257,250 | 0 | true | 2022-05-12T05:09:16.227Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Nginx cofig can't read the static with 404 ERR_ABORTED<ul>
<li>system: ubuntu 18.04.5 LTS</li>
<li>nginx: nginx/1.14.0 (Ubuntu)</li>
</ul>
<p>Hi, I am trying... |
72,182,958 | yarn install doesn't work with docker-compose<p>docker-compose version: <code>docker-compose version 1.29.2, build 5becea4c</code></p>
<p>I have a <code>create-react-app</code> project with the following <code>Dockerfile</code>:</p>
<pre><code>FROM node:lts-alpine as dev
WORKDIR /app
COPY . ./
RUN yarn --ignore-scripts... | <p>What fixed the issue is adding <code>node_modules</code> as a volume for <code>ui</code> in <code>docker-compose.yml</code>:</p>
<pre><code>version: '3.8'
services:
backend_service:
SOME_STUFF
ui:
build:
context: ./my-ui
dockerfile: Dockerfile
target: dev
expos... | yarn install doesn't work with docker-compose | docker-compose|yarnpkg | 0 | 812 | 1 | 72,213,079 | 72,213,079 | 0 | true | 2022-05-10T08:24:39.023Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
yarn install doesn't work with docker-compose<p>docker-compose version: <code>docker-compose version 1.29.2, build 5becea4c</code></p>
<p>I have a <code>crea... |
72,116,478 | Visual studio pack NuGet without building folder<p>I have a working visual studio 2019 project with a simple nuget package, where if I right click 'ClassLibrary2' and click 'pack' it packages my project into a NuGet package</p>
<p><a href="https://i.stack.imgur.com/96o8C.png" rel="nofollow noreferrer"><img src="https:/... | <p>After trying I can't reproduce your issue on my side, please check your project's csproj file, and refer to this document: <a href="https://docs.microsoft.com/en-us/visualstudio/msbuild/how-to-exclude-files-from-the-build?view=vs-2022" rel="nofollow noreferrer">How to: Exclude files from the build</a>.</p> | Visual studio pack NuGet without building folder | c|visual-studio|nuget|visual-studio-2019 | 0 | 35 | 1 | 72,121,746 | 72,121,746 | 0 | true | 2022-05-04T16:33:36.497Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Visual studio pack NuGet without building folder<p>I have a working visual studio 2019 project with a simple nuget package, where if I right click 'ClassLibr... |
72,233,660 | pass variables from front to backend<p>i have a vue js project with front end and i have a field with variables that i want it when its changed it will go to backend and change there too any idea? the variable is id tage like in this code</p>
<pre><code>app.get('/payments', (request, response) => {
response.set('A... | <p>Make the ID part of the request url:</p>
<pre class="lang-js prettyprint-override"><code>// backend assuming this is express
app.get('/payments/:id', (request, response) => {
// use the id in some way
const idtag = req.params.id;
...
});
</code></pre>
<p>In your frontend code, you need to <a href="htt... | pass variables from front to backend | javascript|node.js|vue.js|vuex|quasar | 0 | 396 | 1 | 72,233,963 | 72,233,963 | 0 | true | 2022-05-13T17:52:15.023Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
pass variables from front to backend<p>i have a vue js project with front end and i have a field with variables that i want it when its changed it will go to... |
72,180,937 | How to pass NTLM credentials using angular http post call?<p>I am working on localhost where angular and web api using 2 different ports that's causing issue now.</p>
<p>I am trying to call web api c# from angular like this</p>
<blockquote>
<pre><code>this.http.post<AccessToken>(`${this.url}/api/Home/Eid/?code=12... | <p>I have modified my angular post call to this</p>
<pre><code> return
this.http.post<AccessToken>(`${this.url}/api/Home/Eid/?code=12345sfffs`,{headers:this.httpHeaders},{
withCredentials: true })
.pipe(Response => {
console.log("hi");
console.log(Response);
retur... | How to pass NTLM credentials using angular http post call? | angular|asp.net-web-api|http-status-code-401|ntlm-authentication | 0 | 600 | 1 | 72,181,606 | 72,181,606 | 0 | true | 2022-05-10T04:59:04.863Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to pass NTLM credentials using angular http post call?<p>I am working on localhost where angular and web api using 2 different ports that's causing issue... |
72,181,321 | Custom Event Listener for Keycloak of version 18.0.0<p>I am trying to create an event listener for Keycloak:
<a href="https://i.stack.imgur.com/8RuB6.png" rel="nofollow noreferrer">Project structure and META-INF.services.org.keycloak.events.EventListenerProviderFactory</a></p>
<p>CustomEventListenerProviderFactory:</p>... | <p><a href="https://i.stack.imgur.com/kNvYf.png" rel="nofollow noreferrer">Png</a></p>
<p>Just put the provider files in the providers folder.
Put the theme files in the theme folder.
No more, no less.
Also read READMNE.md in those folders....</p> | Custom Event Listener for Keycloak of version 18.0.0 | java|windows|keycloak|event-listener|keycloak-services | 0 | 760 | 1 | 72,218,049 | 72,218,049 | 0 | true | 2022-05-10T05:53:35.500Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Custom Event Listener for Keycloak of version 18.0.0<p>I am trying to create an event listener for Keycloak:
<a href="https://i.stack.imgur.com/8RuB6.png" re... |
72,165,320 | Angular/Jest - Test that the subject has thrown error after setter is called<p>I have a class that is responsible for setting the theme for my application.</p>
<p>I'm trying to test that it throws an error if you give it a theme that it does not recognise. The code is shown below -</p>
<pre class="lang-js prettyprint-o... | <p>As @Drenai said, there was no need for the <code>BehaviourSubject</code>. I've removed the behaviour subject and the service has become clean and should be easy to test.</p>
<p>Refactor:</p>
<pre class="lang-js prettyprint-override"><code>@Injectable()
export class ThemeSwitcherService {
public static THEME_NAME... | Angular/Jest - Test that the subject has thrown error after setter is called | angular|typescript|unit-testing|jestjs | 0 | 130 | 2 | 72,221,660 | 72,221,660 | 0 | true | 2022-05-08T21:48:42.743Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Angular/Jest - Test that the subject has thrown error after setter is called<p>I have a class that is responsible for setting the theme for my application.</... |
72,173,550 | How to make a music bot join the voice call<p>So i have been seeing many youtube vids and got a working code
but I cannot find the error in my code</p>
<pre class="lang-py prettyprint-override"><code>import discord
from discord import Embed
from itertools import cycle
import os
import asyncio
import random
import json
... | <p>Try to replace</p>
<pre><code>if ctx.voice_client is None:
</code></pre>
<p>with</p>
<pre><code>voice = discord.utils.get(client.voice_clients, guild=ctx.guild)
if voice == None:
await voice_channel.connect()
</code></pre>
<p>Alternatively:</p>
<pre><code> async def join(self, ctx):
member = utils.find(l... | How to make a music bot join the voice call | python|discord|discord.py|bots|pytube | 0 | 118 | 1 | 72,187,358 | 72,187,358 | 0 | true | 2022-05-09T14:21:23.460Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to make a music bot join the voice call<p>So i have been seeing many youtube vids and got a working code
but I cannot find the error in my code</p>
<pre ... |
72,151,709 | What does "%%%ds" mean in a c program formatting text?<p>This c code I wrote below to centre text in strings works.
I cannot find an explanation of what "%%%ds" in the program means and how it works.
There is d for int and s for string but the three percentage symbols is obscure to me.
What does "%%%ds&q... | <p>After this call</p>
<pre><code>sprintf ( format, "%%%ds\n", length );
</code></pre>
<p>the string format will look like</p>
<pre><code>"%Ns\n"
</code></pre>
<p>where N is the value of the expression length.</p>
<p>The two adjacent symbols <code>%%</code> are written in the string format as one sy... | What does "%%%ds" mean in a c program formatting text? | c|printf|conversion-specifier | 0 | 78 | 1 | 72,151,845 | 72,151,845 | 0 | true | 2022-05-07T10:40:28.647Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
What does "%%%ds" mean in a c program formatting text?<p>This c code I wrote below to centre text in strings works.
I cannot find an explanation of what &quo... |
72,202,861 | foreign key does not update in the target table<p>got another question.</p>
<p>I have a dropdown box that display a list of city (table city [city_id, name, postalcode, ...])</p>
<pre><code><option value="idOfTheCity">NameOfTheCity<option>
</code></pre>
<p>When i selected another town it does not ... | <p>Ok i found a solution:</p>
<p>Added</p>
<pre><code>payload.site = {site_id: payload.site};
</code></pre>
<p>in the file [vehicule.ts]</p>
<pre><code> update(): void {
if (this.formGroup.valid) {
const payload: VehiculeUpdatePayload = this.formGroup.value;
payload.vehicule_id = this.detail.vehicule_i... | foreign key does not update in the target table | angular|typescript|spring-boot | 0 | 33 | 1 | 72,439,176 | 72,439,176 | 0 | true | 2022-05-11T14:30:07.637Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
foreign key does not update in the target table<p>got another question.</p>
<p>I have a dropdown box that display a list of city (table city [city_id, name, ... |
72,179,696 | Web-scraping using python<p>I am trying to extract data from this <a href="https://portal.themlc.com/search" rel="nofollow noreferrer">website</a>, It is almost impossible to scrape as after any search it's not changing its URL.</p>
<p>I want to search based on <em>PUBLISHER IPI</em> <em>'00144443097'</em> and extract ... | <p>When the url doesn't change, you can use the developer tools to see if an api is being called. In this case there are two apis. One gives basic information about the writer and the other gives the information on the works. You can parse the json response however you wish from here.</p>
<p>Note: this a post, not a ge... | Web-scraping using python | pandas|web-scraping|beautifulsoup|request|urllib | 0 | 114 | 2 | 72,180,064 | 72,180,064 | 0 | true | 2022-05-10T01:11:33.160Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Web-scraping using python<p>I am trying to extract data from this <a href="https://portal.themlc.com/search" rel="nofollow noreferrer">website</a>, It is alm... |
72,169,502 | Providing test cases to Pester V5 test<p>I'm trying to write a pester test (v5) to see if various services are running on remote computers. This is what I have, which works:</p>
<pre><code>$Hashtable = @(
@{ ComputerName = "computer1"; ServiceName = "serviceA" }
@{ ComputerName = &qu... | <p>If the list of servers and services will change often, it would be a good idea to read it from a separate file, especially if you have the tests under version control. This way you can easily see in the history that only the test data has changed, but the test logic didn't.</p>
<p>A good file format for the given te... | Providing test cases to Pester V5 test | powershell|pester|pester-5 | 0 | 46 | 1 | 72,170,436 | 72,170,436 | 0 | true | 2022-05-09T09:09:50.247Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Providing test cases to Pester V5 test<p>I'm trying to write a pester test (v5) to see if various services are running on remote computers. This is what I ha... |
72,233,665 | Am unable to receive HTTP responses with UIViewController set as URLSessionDelegate<p><strong>Wed 5/18 Additional Info added at Step 5</strong></p>
<p>I am able to create a URLSesion, build a request with a file to upload and successfully call it from my app. On my server side, the proper script is called, uploaded fil... | <p>For other newbies also stuck on this, it turns out there's more than one delegate to look at. There are:</p>
<p>URLSessionTaskDelegate, URLSessionDataDelegate, URLSessionDownloadDelegate, and more. So obviously I was using the wrong one, might have been fell trap to "autocomplete." Nevertheless, I have to ... | Am unable to receive HTTP responses with UIViewController set as URLSessionDelegate | swift|urlsession | 0 | 32 | 1 | 72,295,039 | 72,295,039 | 0 | true | 2022-05-13T17:52:46.253Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Am unable to receive HTTP responses with UIViewController set as URLSessionDelegate<p><strong>Wed 5/18 Additional Info added at Step 5</strong></p>
<p>I am a... |
72,188,302 | type 'Future<dynamic>' is not a subtype of type 'Widget'. flutter<h3>The idea</h3>
<p>I want to display followers. the page take list of followers user id and then display their username.</p>
<hr />
<h2>Error</h2>
<p>when I tried to I get an Error say <code>type 'Future<dynamic>' is not a subtype of type 'Widget'... | <p>I feel this may be the culprit:
<code>usersData.add( getUser(user));</code>.</p>
<p>Try this instead: <code>await usersData.add( getUser(user));</code>.</p>
<p>As you call the async method <code>getUser(user) async { ... }</code> it returns a Future, and this Future gets added to the List not the <code>user</code>. ... | type 'Future<dynamic>' is not a subtype of type 'Widget'. flutter | firebase|flutter|android-studio|dart|future | 0 | 37 | 1 | 72,188,804 | 72,188,804 | 0 | true | 2022-05-10T14:34:46.477Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
type 'Future<dynamic>' is not a subtype of type 'Widget'. flutter<h3>The idea</h3>
<p>I want to display followers. the page take list of followers user id an... |
72,143,595 | Handle movement after collision is detected<p>I'm making a small platformer in js and I'm having trouble with the collisions. Unfortunately it seems that 90% of the info online is detecting the collisions, and not what comes after. I can easily detect collisions as everything in my game is an axis aligned 2d rectangle,... | <p>Your code seems to not check where the nearest face collides just that it is the nearest face after collision. Which could cause this kind of problem:</p>
<p><a href="https://i.stack.imgur.com/R0nPU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/R0nPU.png" alt="Collision detected after wall" /></... | Handle movement after collision is detected | javascript|game-engine|game-physics | 0 | 103 | 1 | 72,144,665 | 72,144,665 | 0 | true | 2022-05-06T15:00:49.323Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Handle movement after collision is detected<p>I'm making a small platformer in js and I'm having trouble with the collisions. Unfortunately it seems that 90%... |
72,173,858 | Parse XML from Google Drive in Javascript (Google Scripts)<p>I would like to ask you, please, how to parse this XML file? I would like to work with a couple of child nodes.</p>
<pre><code><are:Ares_odpovedi xmlns:are="http://wwwinfo.mfcr.cz/ares/xml_doc/schemas/ares/ares_answer_vreo/v_1.0.0" odpoved_datum_... | <p>Replace</p>
<pre><code>var xml = UrlFetchApp.fetch("https://drive.google.com/file/d/[fileID]").getContentText();
</code></pre>
<p>by</p>
<pre><code>var xml = DriveApp.getFileById(fileID).getBlob().getDataAsString();
</code></pre>
<hr>
<p>As your script is using UrlFetchApp to retrieve a Google Drive file u... | Parse XML from Google Drive in Javascript (Google Scripts) | javascript|google-apps-script | 0 | 634 | 1 | 72,174,031 | 72,174,031 | 0 | true | 2022-05-09T14:42:53.487Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Parse XML from Google Drive in Javascript (Google Scripts)<p>I would like to ask you, please, how to parse this XML file? I would like to work with a couple ... |
72,189,458 | Toast not showing up?<p>When I add toast to a function and run or debug that function the toast doesn't show, no errors in the log, and any logged messages before or after it do show in the console. However when I place the exact same toast code in a blank spreadsheet's apps script, the toast does show.</p>
<pre><code>... | <p>In order to make the Google Sheets UI methods like <code>toast</code> work properly,</p>
<ol>
<li>The script should be bounded to a spreadsheet or it should be an Editor add-on</li>
<li>If the script will be run from the Google Apps Script Editor, it should be opened through the Google Sheets user interface:
<ol>
<l... | Toast not showing up? | google-apps-script|google-sheets | 0 | 50 | 1 | 72,189,888 | 72,189,888 | 0 | true | 2022-05-10T15:51:17.407Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Toast not showing up?<p>When I add toast to a function and run or debug that function the toast doesn't show, no errors in the log, and any logged messages b... |
72,159,276 | dynamically select this.variable angular 12<p>I have problem with selecting variables predefined in component.
these are variables:</p>
<pre><code>public editable1: number = 0;
public editable2: number = 0;
public editable3: number = 0;
public editable4: number = 0;
public editable5: number = 0;
</code></pre>
<p>next a... | <p>You can cast your component as any, and then you can access its properties with ['prop_name'] sytnax:</p>
<pre class="lang-js prettyprint-override"><code>this.editors.forEach((element) => {
element.forEach((e) => {
(this as any)[e]++;
});
});
</code></pre> | dynamically select this.variable angular 12 | typescript|angular12 | 0 | 174 | 1 | 72,159,380 | 72,159,380 | 0 | true | 2022-05-08T08:28:16.693Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
dynamically select this.variable angular 12<p>I have problem with selecting variables predefined in component.
these are variables:</p>
<pre><code>public edi... |
72,117,679 | How to create an array that has in each index a string depending on the data type?<p>I have an array with an object nested in it. I'm trying to use <code>map()</code> to create an array that has in each index the string <code>"war"</code> or <code>"peace"</code>. The string "war" if the <c... | <p>I think what you're trying to do is check the list of pets to see if it contains a "dog" type and a "cat" type for any given person. In that case, what you can do is map the pet types into a <code>Set</code> (to get a list of unique pet types) for each person, and then check whether that Set cont... | How to create an array that has in each index a string depending on the data type? | javascript|arrays|object|ecmascript-6 | 0 | 32 | 2 | 72,118,732 | 72,118,732 | 0 | true | 2022-05-04T18:16:10.233Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to create an array that has in each index a string depending on the data type?<p>I have an array with an object nested in it. I'm trying to use <code>map... |
72,229,672 | Using backspace across multiple tkinter Entry widgets<p>I made wordle (using tkinter) in a previous project of mine, and now instead of using one entry to get the guess, I want 5 entries linked together that work like the blocks in:</p>
<p><a href="https://i.stack.imgur.com/YGhgL.png" rel="nofollow noreferrer"><img src... | <p>First, you have to get something to register a button press. For this, I imported <code>keyboard</code> and used <code>if keyboard.is_pressed("backspace"):</code> to see if backspace was pressed.</p>
<p>Unfortunately, when a human presses a button, we hold it down for a few milliseconds so to the computer,... | Using backspace across multiple tkinter Entry widgets | python|tkinter|keyboard-events|tkinter-entry | 0 | 70 | 1 | 72,263,375 | 72,263,375 | 0 | true | 2022-05-13T12:32:53.760Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Using backspace across multiple tkinter Entry widgets<p>I made wordle (using tkinter) in a previous project of mine, and now instead of using one entry to ge... |
72,226,236 | regex - Filter out year from a date string in an array of objects<p>I'm trying to filter out year out of this array of objects (in React)</p>
<pre><code>2021-12-20,
2021-12-21,
2021-12-22,
(...)
2022-01-28,
2022-01-31,
2022-02-01,
</code></pre>
<p>It has 100 entries.</p>
<p>Anyways, this is what I have so far:</p>
<pre... | <p>Assuming these are date strings, you may use <code>match</code> here:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>stockDates = ['2021-12-20', '2021-12-21', '2021-12-22']... | regex - Filter out year from a date string in an array of objects | javascript|reactjs|string|sorting | 0 | 36 | 1 | 72,226,266 | 72,226,266 | 0 | true | 2022-05-13T07:59:19.353Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
regex - Filter out year from a date string in an array of objects<p>I'm trying to filter out year out of this array of objects (in React)</p>
<pre><code>2021... |
72,076,055 | Tailwind, Vue problem with non-English characters when using tags right after eachother<p>I am facing an issue when using tags right after eachother(ex: <code>span</code>, 'a' and 'p').
characters merge with each other, although they are in seperate html tags!</p>
<p>How can I prevent that from happing?</p>
<pre class=... | <p>The solution is to use <code>&nbsp;</code> because every character in between tags, will prevent the issue from happening.</p>
<pre class="lang-html prettyprint-override"><code> <span>قوانین و شرایط استفاده</span>
&nbsp;
<span>حریم شخصی</span>
</code></pre>
<p>result:</p>
<... | Tailwind, Vue problem with non-English characters when using tags right after eachother | css|vue.js|tailwind-css|font-face|tailwind-3 | 0 | 33 | 2 | 72,076,056 | 72,076,056 | 0 | true | 2022-05-01T10:54:58.923Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Tailwind, Vue problem with non-English characters when using tags right after eachother<p>I am facing an issue when using tags right after eachother(ex: <cod... |
72,041,889 | Is it possible to combine console.timeEnd() and console.debug()?<p>I would like to measure time in browser javascript.</p>
<p>I use console.log(), console.debug() ...etc.</p>
<p>But console.timeEnd() behavior is similar to console.log(). It's wrote to console in case of "log" switch is on in browser's JS-Cons... | <p>There's nothing <a href="https://console.spec.whatwg.org/" rel="nofollow noreferrer">built in</a> that will do that for you, but it's very easy to implement it yourself: Maintain a <code>Map</code> of labels to start times, and use <code>Date.now()</code> or <code>performance.now()</code> to get the start and end ti... | Is it possible to combine console.timeEnd() and console.debug()? | javascript|debugging | 0 | 24 | 1 | 72,041,960 | 72,041,960 | 0 | true | 2022-04-28T10:13:18.120Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is it possible to combine console.timeEnd() and console.debug()?<p>I would like to measure time in browser javascript.</p>
<p>I use console.log(), console.de... |
72,198,303 | How to fix "Type 'string | boolean' is not assignable to type 'never'. Type 'string' is not assignable to type 'never'"?<pre><code>interface IData {
title: string;
slug: string;
published_at: string;
isPopular: boolean;
}
const product: IData = {
title: "Title 1",
slug: "title-1&... | <p>There are two distinct issues:</p>
<ol>
<li><p>Your <code>items</code> is not a valid <code>IData</code> object. It doesn't have all of the required <code>IData</code> properties.</p>
</li>
<li><p>In your loop, TypeScript doesn't know the specific type of <code>field</code> (just that it's one of <code>keyof IData</... | How to fix "Type 'string | boolean' is not assignable to type 'never'. Type 'string' is not assignable to type 'never'"? | typescript | 0 | 259 | 2 | 72,198,550 | 72,198,550 | 0 | true | 2022-05-11T09:05:57.273Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to fix "Type 'string | boolean' is not assignable to type 'never'. Type 'string' is not assignable to type 'never'"?<pre><code>interface IData {
titl... |
72,214,622 | Changing two states with one button click<p>I'm new to react and trying to change two states with one button click. Ultimately I want to hide one component and unhide the other when I click a button.</p>
<p>The code works when changing one state, but not with two</p>
<pre><code>import React from 'react'
import Buttons ... | <p>You can use regular if else</p>
<pre class="lang-js prettyprint-override"><code>const showSignInBtn = () => {
if (!showSignIn) {
setShowSignIn(true)
setShowButtons(false)
} else {
setShowSignIn(false)
}
}
</code></pre> | Changing two states with one button click | javascript|reactjs | 0 | 259 | 2 | 72,214,747 | 72,214,747 | 0 | true | 2022-05-12T11:21:27.283Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Changing two states with one button click<p>I'm new to react and trying to change two states with one button click. Ultimately I want to hide one component a... |
72,181,278 | Simple Vue example not working only producing the brackets<p>Can someone help me with this.</p>
<p>I have looked at other eksampels inkluding: <a href="https://stackoverflow.com/questions/49152598/simple-vue-slot-example-not-working">Simple Vue slot example not working</a></p>
<p>and</p>
<p><a href="https://stackoverfl... | <p>You have mixed vue 2 code with vue 3 that's why</p>
<p>if you want to use vue 3 you need to use Vue.createApp function</p>
<pre><code>const app = Vue.createApp({
data() {
return {
numbers: [1, 10, 100, 1000, 10000]
}
})
app.mount('#app')
</code></pre>
<p>if you want to use vue 2... | Simple Vue example not working only producing the brackets | html|vue.js | 0 | 26 | 1 | 72,181,352 | 72,181,352 | 0 | true | 2022-05-10T05:48:09.540Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Simple Vue example not working only producing the brackets<p>Can someone help me with this.</p>
<p>I have looked at other eksampels inkluding: <a href="https... |
72,153,820 | Adding CASE function to this existing query?<p>I have been trying to <strong>add a CASE function</strong> without success. [MySQL 8.0]</p>
<pre><code>SELECT *
, LEAD(total_weight, 1) OVER(
ORDER BY weight_date DESC
) AS prev_total_weight
, MIN(total_weight) OVER() AS lowest_weight
... | <p>window function values, can not be access during processing time, the value is always 0, what ,akes them annoying.</p>
<p>You must first process all data . like on my new query in a CTE
and make after that your <code>CASE WHEN</code></p>
<blockquote>
<pre><code>CREATE TABLE YourTable
(`_ID` int, `weight_date` b... | Adding CASE function to this existing query? | mysql|sql | 0 | 54 | 1 | 72,153,906 | 72,153,906 | 0 | true | 2022-05-07T15:16:51.483Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Adding CASE function to this existing query?<p>I have been trying to <strong>add a CASE function</strong> without success. [MySQL 8.0]</p>
<pre><code>SELECT ... |
72,205,228 | Find customers that never placed an order with an employee<p>We have the following details from the output of a query a supplier id, a category name, and product count,<br />
so 3 columns. Each supplier holds a certain category of products, and for each<br />
category, the third column lists the number of products in t... | <p>you could use these two possibilities</p>
<p>As joined table</p>
<pre><code>SELECT s.SupplierID, s.CompanyName AS Supplier, cat.CategoryName,
COUNT(*) * 100/ total as percentage_count
FROM suppliers AS s
JOIN products AS p ON s.SupplierID = p.SupplierID
JOIN categories AS cat ON p.CategoryID = cat.CategoryID ... | Find customers that never placed an order with an employee | mysql|sql | 0 | 41 | 1 | 72,205,481 | 72,205,481 | 0 | true | 2022-05-11T17:25:38.953Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Find customers that never placed an order with an employee<p>We have the following details from the output of a query a supplier id, a category name, and pro... |
72,236,997 | Has Flutter v3.0.0 come with any performance gains?<p>I'm on the fence about upgrading to 3.0.0, mainly because not all my dependencies have moved there yet.</p>
<p>So I'm wondering, how critical it is to upgrade to it at this point in time. If there are any appreciable performance gains in regards to iOS performance ... | <p>According to my research there were many new updates on ios, android, windows and even linux</p>
<p>According to the documentation it says that "Flutter 3.0 offers improved performance, better Material You support, and new Dart language features."</p>
<p>some of the other updates:</p>
<p>MacOS and Linux su... | Has Flutter v3.0.0 come with any performance gains? | flutter | 0 | 148 | 2 | 72,237,035 | 72,237,035 | 0 | true | 2022-05-14T02:59:09.563Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Has Flutter v3.0.0 come with any performance gains?<p>I'm on the fence about upgrading to 3.0.0, mainly because not all my dependencies have moved there yet.... |
72,164,249 | Generate bearer token for google cloud function - Java<p>I'm trying to connect to cloud function such as https://us-west1-<>.cloudfunctions.net from java, and I'm trying to generate the bearer token for this function using a code as follows:</p>
<pre><code>String audience = https://<projectname>-<region&... | <p>This issue got fixed when I used the correct audience value as below.</p>
<p>https://<strong>function-url</strong>/projects/<strong>project-id</strong>/locations/<strong>region</strong>/functions/<strong>function-name</strong></p>
<p>In the above URI, replace function-url, project-id, region, and function-name with ... | Generate bearer token for google cloud function - Java | google-cloud-functions|serverless | 0 | 574 | 1 | 72,204,965 | 72,204,965 | 0 | true | 2022-05-08T18:59:46.540Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Generate bearer token for google cloud function - Java<p>I'm trying to connect to cloud function such as https://us-west1-<>.cloudfunctions.net from ja... |
72,234,369 | find_package() ignores <PackageName>_ROOT<p>In my CMake script I append the path to a folder containing <code><PackageName>Config.cmake</code> to <code><PackageName>_ROOT</code> and then call <code>find_package(<PackageName> REQUIRED)</code> but it can't find my package.</p>
<p>When I use <code>CMAKE_... | <p>Since you are providing a config file, you should set <code><PackageName>_DIR</code> to where you have the config, not <code><PackageName>_ROOT</code> (which is a hint for find modules and isn't really needed when you have a path to the config).</p>
<hr />
<p>If you don't know the path exactly, or want t... | find_package() ignores <PackageName>_ROOT | c++|opencv|cmake|build|find-package | 0 | 67 | 1 | 72,237,625 | 72,237,625 | 0 | true | 2022-05-13T19:05:16.927Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
find_package() ignores <PackageName>_ROOT<p>In my CMake script I append the path to a folder containing <code><PackageName>Config.cmake</code> to <code... |
72,076,837 | Mongo eval arguments taken from a list bash script<p>I am working on a bash script and would like to have a for loop iterate over specific collections in mongo and perform a count. If any of these specific collections is non-zero, then break the loop.</p>
<p>I have initialize this variable inside my script (assume the ... | <p>Should be rather this:</p>
<pre><code>db_collections=(collectionA collectionB collectionC....)
for str in ${db_collections[@]}; do
mongo "$MONGO_CONN_CONF" --quiet --eval "db.${str}.count();"
done
</code></pre>
<p>or</p>
<pre><code>for str in ${db_collections[@]}; do
mongo "$MONGO_C... | Mongo eval arguments taken from a list bash script | mongodb|bash | 0 | 32 | 1 | 72,077,229 | 72,077,229 | 0 | true | 2022-05-01T12:46:36.560Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Mongo eval arguments taken from a list bash script<p>I am working on a bash script and would like to have a for loop iterate over specific collections in mon... |
72,180,283 | How to insert selected result from a table into another table on Android Room's DAO class<p>I've been developing a budget spending tracking app on Android Studio.
In this particular part, what I want to do is to insert the selected result of a table "budget_tracker_table" into another table "budget_track... | <p>Room's <code>@Insert</code> is a convenience insert, it expects an object (or list of objects) only and that object being an object of the type/class of the respective entity.</p>
<p>You need to use @Query with the SQL to insert, so</p>
<pre><code>@Query("insert into budget_tracker_table_alias (date_alias, stor... | How to insert selected result from a table into another table on Android Room's DAO class | java|android|sql|sqlite|dao | 0 | 30 | 1 | 72,181,418 | 72,181,418 | 0 | true | 2022-05-10T03:02:19.360Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to insert selected result from a table into another table on Android Room's DAO class<p>I've been developing a budget spending tracking app on Android St... |
72,219,188 | Extract Nested Tag Using PHP<p><strong>Tag hierarchy in a webpage :</strong></p>
<pre><code><body>
<div id='header'>
<h2>.....</h2>
</div>
<div id='main'>
<h2>...</h2>
//Some other content
<h2>...</h2>
</div>
<di... | <p>I have updated this to PHP:</p>
<p><code>h2_tags</code> below will get list of h2s in <code>main div</code>:</p>
<pre><code>$div_m = $htmlDom->getElementById('main');
$h2_tags = $div_m->getElementsByTagName('h2');
</code></pre>
<p>This is JS:</p>
<pre><code>var div_m = document.getElementById("main")... | Extract Nested Tag Using PHP | php|html|web | 0 | 36 | 1 | 72,219,270 | 72,219,270 | 0 | true | 2022-05-12T16:30:50.987Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Extract Nested Tag Using PHP<p><strong>Tag hierarchy in a webpage :</strong></p>
<pre><code><body>
<div id='header'>
<h2>.....<... |
72,170,625 | filter array link node<p>I'm new react developer, here i'm using 'react-d3-graph' to get my nodes and links, at the moment using 'info' i'm successfully getting 3 nodes and two links, those links connect to nodes. for example link with 'target:1' is connected to node 'id:1' and link with 'target:2' is connected to node... | <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>const testThis = {
identifier: "gDUy",
}
const info = {
links: [{
id: 0,
source: 0,
target: 1,
color: ... | filter array link node | javascript|arrays|reactjs|object | 0 | 84 | 1 | 72,170,891 | 72,170,891 | 0 | true | 2022-05-09T10:36:50.617Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
filter array link node<p>I'm new react developer, here i'm using 'react-d3-graph' to get my nodes and links, at the moment using 'info' i'm successfully gett... |
72,188,010 | Why does this merge sort produce an index out of bounds exception when sorting a second array at the same time?<p>I've been working on a merge sort algorithm, which I want to use to sort a string array eventually.</p>
<p>The theory is that I sort an array containing the IDs that I want to sort in the same order as the ... | <p>When you use <code>k++</code> <code>j++</code> etc. you increase the variable. You do this for both the left and the right array. But you probably only want to do it once, not twice.</p>
<p>You want to replace code like this:</p>
<pre><code>if (leftArr[i] <= rightArr[j]) {
flightIDArr[k++] = leftArr[i++];
... | Why does this merge sort produce an index out of bounds exception when sorting a second array at the same time? | java | 0 | 38 | 1 | 72,188,178 | 72,188,178 | 0 | true | 2022-05-10T14:16:39.887Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why does this merge sort produce an index out of bounds exception when sorting a second array at the same time?<p>I've been working on a merge sort algorithm... |
72,228,278 | Copy dockerfile files ADD instruction in superset<p>I have the following DockerFile</p>
<pre><code>FROM apache/superset:pr-19860
RUN pip install elasticsearch-dbapi
RUN superset superset fab create-admin \
--username admin \
--firstname Superset \
--lastname Admin \
... | <p>The superset image is set up to run as the user <code>superset</code> which doesn't have full permissions. So before your change anything, you should switch to <code>root</code> and then back to the <code>superset</code> user when you´re done.</p>
<p>You can see an example at the bottom of the page for the image (un... | Copy dockerfile files ADD instruction in superset | python|docker|docker-compose|dockerfile|apache-superset | 0 | 324 | 2 | 72,229,289 | 72,229,289 | 0 | true | 2022-05-13T10:41:24.610Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Copy dockerfile files ADD instruction in superset<p>I have the following DockerFile</p>
<pre><code>FROM apache/superset:pr-19860
RUN pip install elasticsearc... |
72,143,384 | why ggplot and geom_tile create lines on the map?<p>Data: <a href="https://github.com/yuliaUU/data/blob/main/test.csv" rel="nofollow noreferrer">https://github.com/yuliaUU/data/blob/main/test.csv</a></p>
<pre><code>griddf <- read_csv("test.csv")
</code></pre>
<p>create a map:</p>
<pre><code>world <- rn... | <p>You basically answered the question yourself - your data is too granular. For a more "complete" look, you might want to 2d-interpolate the values. Here, I am using <code>akima::interp</code>, but there are other functions out there - this is not the place to discuss which is the best to use.</p>
<pre class... | why ggplot and geom_tile create lines on the map? | r|ggplot2|raster | 0 | 80 | 1 | 72,144,872 | 72,144,872 | 0 | true | 2022-05-06T14:47:53.470Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
why ggplot and geom_tile create lines on the map?<p>Data: <a href="https://github.com/yuliaUU/data/blob/main/test.csv" rel="nofollow noreferrer">https://gith... |
72,233,926 | How to use Primary Refresh Token (PRT) to retrieve Access Token in AzureAD<p>Is it possible to use a Windows PRT in browser to receive Access Token to call an Azure protected web API from a web app?</p> | <p>Please check this concept of <a href="https://docs.microsoft.com/en-us/azure/active-directory/devices/concept-primary-refresh-token" rel="nofollow noreferrer">primary refresh token in Azure AD</a> which says</p>
<blockquote>
<p>A Primary Refresh Token (PRT) is a key artifact of Azure AD
authentication on Windows 10 ... | How to use Primary Refresh Token (PRT) to retrieve Access Token in AzureAD | azure-active-directory|access-token | 0 | 666 | 1 | 72,234,995 | 72,234,995 | 0 | true | 2022-05-13T18:19:24.137Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to use Primary Refresh Token (PRT) to retrieve Access Token in AzureAD<p>Is it possible to use a Windows PRT in browser to receive Access Token to call a... |
72,205,092 | php displayes wrong data from db<p>I am trying to display the highest temperature and the day that temperature was recorded. It displays the correct temperature but the wrong date. I don't know if I am going crazy, but I am quite sure it worked just fine before. Here is the query request.</p>
<pre><code>$statment = $pd... | <p>Try something this:</p>
<pre><code>$statment = $pdo->prepare('SELECT temperature, date FROM 4pmweather WHERE temperature=(SELECT MAX(temperature) FROM 4pmweather)');
</code></pre>
<p>Otherwise you will get the max value from the temperature column and the first id.</p>
<p>Just note that if max temperature is not ... | php displayes wrong data from db | php|mysql | 0 | 32 | 2 | 72,205,248 | 72,205,248 | 0 | true | 2022-05-11T17:15:16.997Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
php displayes wrong data from db<p>I am trying to display the highest temperature and the day that temperature was recorded. It displays the correct temperat... |
72,214,054 | Concatenate two strings elements wise<p>I came across a problem in which i had to concatenate two string element wise
for ex :</p>
<pre><code>str1 = "ABCD"
str2 = "EFGH"
output = "AEBFCGDH"
</code></pre>
<p>I wrote this code</p>
<pre><code>op = ''
op = op.join([i + j for i, j in zip(str1, ... | <p>You could take the shorter string, zip until its length and then concatenate the remaining part of the longer string.
eg:</p>
<pre><code>str1 = 'ABC'
str2 = 'DEFGH'
op = ''
if len(str1)>len(str2):
op = op.join([i + j for i, j in zip(str1, str2)])+str1[len(str2):]
else:
op = op.join([i + j for i, j in zip(... | Concatenate two strings elements wise | python|string|string-concatenation | 0 | 32 | 3 | 72,214,150 | 72,214,150 | 0 | true | 2022-05-12T10:35:16.650Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Concatenate two strings elements wise<p>I came across a problem in which i had to concatenate two string element wise
for ex :</p>
<pre><code>str1 = "AB... |
72,148,053 | How do I make my setfunction run through my if loop?<p>I am working on a program and I need to make a class about cars. I need to add setFunctions that only allow a car year manufacture of 1930 -2030 as input, anything else will be automatically set as 2012. My code looks like this:</p>
<pre><code>// code will be follo... | <p><code>setYear()</code> and <code>setSpeed()</code> are both making the same mistake. They are not assigning any values to the class data members if the input values are out of range.</p>
<p>Try this instead:</p>
<pre><code>void setYear(int yr)
{
if (yr > 2030 || yr < 1930){
yr = 2012;
}
ye... | How do I make my setfunction run through my if loop? | c++|if-statement|constructor | 0 | 49 | 1 | 72,148,105 | 72,148,105 | 0 | true | 2022-05-06T22:42:09.530Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I make my setfunction run through my if loop?<p>I am working on a program and I need to make a class about cars. I need to add setFunctions that only ... |
72,166,696 | Using "string_view" to represent the "string" key<p>When I use <code>map<string, string> kv;</code> in protobuf 3.8.0, the next code works:</p>
<pre><code>std::string_view key("key");
kv[key] = "value";
</code></pre>
<p>While in protobuf 3.19.4, the above code doesn't work.</p>
<p>The error ms... | <p>In 3.8.0, <code>Map::operator[]</code> is declared as:</p>
<pre><code>Value& operator[](const Key& k)
</code></pre>
<p>Where, in your case, <code>Key</code> is <code>std::string</code>. <code>std::string_view</code> is convertible to <code>std::string</code>, which is why the code works in 3.8.0.</p>
<p>In 3... | Using "string_view" to represent the "string" key | c++|protobuf-c | 0 | 102 | 1 | 72,167,112 | 72,167,112 | 0 | true | 2022-05-09T03:26:40.787Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Using "string_view" to represent the "string" key<p>When I use <code>map<string, string> kv;</code> in protobuf 3.8.0, the next code works:</p>
<pre><c... |
72,230,928 | more concise way to make this?<p>I'm unsure of how to create a certain section of my code without it being excessively long and tedious. Is there perhaps a way of utilizing a range function where I need my elif statements? Any help shortening this would be more than appreciated!</p>
<pre><code>#just some sample lists
P... | <p>To be honest, I think the data format is inappropriate. If you have the ability to change it, I would suggest redesigning your data model to deal with points instead of individual point coordinates <code>(x, y)</code>, e.g.:</p>
<pre class="lang-py prettyprint-override"><code>Player.PlayerList[1].carrier = [(0, 5), ... | more concise way to make this? | python|list | 0 | 47 | 4 | 72,231,199 | 72,231,199 | 0 | true | 2022-05-13T14:07:56.963Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
more concise way to make this?<p>I'm unsure of how to create a certain section of my code without it being excessively long and tedious. Is there perhaps a w... |
72,162,820 | How to hide a chart in a section<p>I have a chart element in a section on my form, I need to hide the chart according to some rules, I know the way to hide a tab or a section but If I want to show/hide chart element according to it's unique name what is the xrm\Js syntax ?</p> | <p>If you see something similar to this on a form:</p>
<p><a href="https://i.stack.imgur.com/hJab5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hJab5.png" alt="chart on form" /></a></p>
<p>It's nothing more than a subgrid set as a chart:</p>
<p><a href="https://i.stack.imgur.com/L24vg.png" rel="no... | How to hide a chart in a section | javascript|dynamics-crm|dynamics-crm-2016 | 0 | 22 | 1 | 72,465,753 | 72,465,753 | 0 | true | 2022-05-08T16:03:52.593Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to hide a chart in a section<p>I have a chart element in a section on my form, I need to hide the chart according to some rules, I know the way to hide a... |
72,200,145 | My Java Program can't connect to the MySQL server<p>Yesterday I spent several hours trying to solve this problem.
When I try to connect to MySQL server from my Java program I get the <code>CommunicationsException: Communications link failure</code>.
I have encountered several questions on Stackoverflow with similar pro... | <p>I have found the solution to my problem and I want to share the solution in case someone else faces the same problem. As Jon Skeet suggested in his comment, the server, for whatever reason, wasn't listening on port 3306.
I confirmed this by logging into the mysql server via terminal (<code>mysql -u root -p</code>) a... | My Java Program can't connect to the MySQL server | java|mysql | 0 | 116 | 1 | 72,215,028 | 72,215,028 | 0 | true | 2022-05-11T11:21:01.127Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
My Java Program can't connect to the MySQL server<p>Yesterday I spent several hours trying to solve this problem.
When I try to connect to MySQL server from ... |
72,220,097 | Optimisation and strict aliasing<p>My question is regarding a code fragment, such as below:</p>
<pre class="lang-cpp prettyprint-override"><code>#include <iostream>
int main() {
double a = -50;
std::cout << a << "\n";
uint8_t* b = reinterpret_cast<uint8_t*>(&a);
b[... | <blockquote>
<p>More specifically, turning on optimisations can the compiler optimise away the middle b[7], either explicitly or implicitly, by simply keeping a in a register through the whole function.</p>
</blockquote>
<p>The compiler can generate the double value 50 as a constant, and pass that directly to the outpu... | Optimisation and strict aliasing | c++|language-lawyer | 0 | 88 | 1 | 72,220,162 | 72,220,162 | 0 | true | 2022-05-12T17:48:35.250Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Optimisation and strict aliasing<p>My question is regarding a code fragment, such as below:</p>
<pre class="lang-cpp prettyprint-override"><code>#include <... |
72,197,281 | How to add new list when I click on the current list<p>I want to do when I click on icon add, it will generate a list of array which I have declare. The list have its own container which have different header 'Surat Rasmi permohonan, surat lantikan peguam'. my current problem is the 3 list comes at once and wrong meth... | <p>Don't declare anything inside <code>build</code> method. Theses variable will reinitialize on state change. Better approach is using <a href="https://api.flutter.dev/flutter/widgets/ListView/ListView.builder.html" rel="nofollow noreferrer"><code>ListView.builder</code></a>. while you like to have separator, use <a h... | How to add new list when I click on the current list | flutter|dart|flutter-layout | 0 | 63 | 2 | 72,197,439 | 72,197,439 | 0 | true | 2022-05-11T07:48:25.127Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add new list when I click on the current list<p>I want to do when I click on icon add, it will generate a list of array which I have declare. The list... |
72,210,666 | Using a variable for milliseconds in setTimeout (javascript)<p>I am using a text area to display the time, an input field to get a number and a button to execute the function:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snip... | <p>This is where you went wrong:-
You are getting the value of the input at the very beginning, when the user has not inputted any value. Thus <code>setTimeout</code> receives a <a href="https://www.w3schools.com/jsref/jsref_number_nan.asp#:%7E:text=In%20JavaScript%2C%20NaN%20is%20short,the%20same%20as%20the%20Number."... | Using a variable for milliseconds in setTimeout (javascript) | javascript|settimeout|parseint | 0 | 169 | 1 | 72,210,789 | 72,210,789 | 0 | true | 2022-05-12T05:51:36.907Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Using a variable for milliseconds in setTimeout (javascript)<p>I am using a text area to display the time, an input field to get a number and a button to exe... |
72,232,858 | Magnolia CMS 6.2 Custom Field<p>How can I get the item value from JCR for custom field factory in Magnolia version 6.2?
In the earlier version of Magnolia, in Abstract FieldFactory implementations was the property Item item. Since version 6.2. it is no longer there.</p>
<p><div class="snippet" data-lang="js" data-hide=... | <p>You can inject <code>ValueContext<Node></code> into the field factory constructor.
Then you can retrieve it via</p>
<pre><code>Node dialogNode = valueContext.getSingleOrThrow();
Property thisFieldProperty = dialogNode.getProperty(getDefinition().getName());
</code></pre>
<p><a href="https://git.magnolia-cms.co... | Magnolia CMS 6.2 Custom Field | java|content-management-system|magnolia | 0 | 140 | 2 | 72,255,760 | 72,255,760 | 0 | true | 2022-05-13T16:40:10.263Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Magnolia CMS 6.2 Custom Field<p>How can I get the item value from JCR for custom field factory in Magnolia version 6.2?
In the earlier version of Magnolia, i... |
72,159,249 | How to print two columns in ascending order from 2 tables without common column<p>this question was asked to me in interview i was not able give a answer i tried every solution internet did not gave desired output in oracle sql
input table table A has ID column and table B has Value columns
``table A`
ID(table A) V... | <p>You can both order your numbers table and the letters table and then join the numbers table with the letters table on the row number of the letter table:</p>
<pre><code>SELECT numbers.id, letters.value FROM
(SELECT id
FROM tableA) numbers
JOIN
(SELECT ROW_NUMBER() OVER(ORDER BY value) id, value
FROM tableB ) letter... | How to print two columns in ascending order from 2 tables without common column | sql|oracle|sql-order-by | 0 | 39 | 3 | 72,159,393 | 72,159,393 | 0 | true | 2022-05-08T08:24:30.623Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to print two columns in ascending order from 2 tables without common column<p>this question was asked to me in interview i was not able give a answer i t... |
72,159,533 | Newbie here: ORA-00907 help me identify?<pre><code>CREATE TABLE PROJECT(
PROJECT_ID INT PRIMARY KEY,
CUSTOMER_ID INT REFERENCES CUSTOMER(CUSTOMER_ID),
PROJECT_DESCRIPTION VARCHAR(30),
PROJECT_DATE DATE,
... | <p>You missed to provide the data type for the column <code>ESTIMATED_END_DATE</code>. It should be something like <code>ESTIMATED_END_DATE DATE</code>, similar to <code>ESTIMATED_START_DATE DATE</code>. And of course, there is needed a comma after this since further columns follow.</p> | Newbie here: ORA-00907 help me identify? | sql|oracle | 0 | 21 | 1 | 72,159,571 | 72,159,571 | 0 | true | 2022-05-08T09:09:07.287Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Newbie here: ORA-00907 help me identify?<pre><code>CREATE TABLE PROJECT(
PROJECT_ID INT PRIMARY KEY,
CU... |
72,223,881 | Replace nested array for new array<p>I have an array inside another array:</p>
<p>Structure:</p>
<pre><code>First Array
[
{
Second Array
[
{
}
]
}
]
</code></pre>
<p>So I want to replace all Second Array for new array that I have so I try this:</p>
<pre><code>this.FirstArray.map(
(myArray) =&g... | <p>You can achieve that by using spread operator and without any loop as you want to replace second array with the new array.</p>
<p>Input array <strong>:</strong></p>
<pre><code>First Array
[{
Second Array
[{}]
}]
</code></pre>
<p>Logic to replace <code>newArray</code> with <code>secondArray</code> <strong>:</str... | Replace nested array for new array | javascript|vue.js|vuejs2 | 0 | 172 | 2 | 72,224,900 | 72,224,900 | 0 | true | 2022-05-13T02:33:49.740Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Replace nested array for new array<p>I have an array inside another array:</p>
<p>Structure:</p>
<pre><code>First Array
[
{
Second Array
[
{
}
... |
72,151,663 | Why is there a gap between the header and the main div?<p>There is a gap between the <code>header</code> and the <code>main</code> that is the same color as the background color I set for the <code>body</code> tag (black). I've tried making <code>overflow: hidden</code> and <code>margin: 0</code> but that did not work ... | <p>It turns out that all I needed to do was make the <code>top-container</code> <code>margin-top: 0</code>. The <code>margin</code> for the top and bottom before was at <code>2rem</code>.</p>
<p>So it looked like:</p>
<pre><code>.top-container {
margin: 0rem 1rem;
display: flex;
flex-direction: column;
... | Why is there a gap between the header and the main div? | html|css|menu|header|nav | 0 | 38 | 2 | 72,151,755 | 72,151,755 | 0 | true | 2022-05-07T10:33:28.643Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why is there a gap between the header and the main div?<p>There is a gap between the <code>header</code> and the <code>main</code> that is the same color as ... |
72,156,622 | How persist two objects related to each other at the same time?<p>I am trying to persist a new <code>JobAdvertise</code> object with a list of new <code>JobAdTasks</code> objects. An advertise contains tasks related to it, both persisted successfully at the same time. However, the foreign key for each <code>JobAdTask</... | <h2>In your service, you need to change to the following:</h2>
<pre class="lang-java prettyprint-override"><code>for (String task : jobAdCreation.getTaskList()) {
JobAdTask jobAdTask = new JobAdTask();
jobAdTask.setTask(task);
jobAdTask.setJobAdvertise(jobAdvertise);
jobAdTask = jobAdTaskRepo.save(jobAdTask... | How persist two objects related to each other at the same time? | java|spring-boot|hibernate|hibernate-mapping | 0 | 72 | 1 | 72,167,873 | 72,167,873 | 0 | true | 2022-05-07T21:57:32.847Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How persist two objects related to each other at the same time?<p>I am trying to persist a new <code>JobAdvertise</code> object with a list of new <code>JobA... |
72,153,336 | Building a referral system using Node/React/MongoDB<p>I am making a referral system for my website. I have two schema one is user and other is referral. The userschema is as follows:</p>
<pre><code>const UserSchema = new Schema({
name: {
type: String,
required: true,
},
email: {
type: String,
requ... | <p><code>How to make this as referral link</code> - When a user is referring any other user and will type the user email, you can save that partcular instance in the DB and you can also track if the referred user is signing from the link or not. You can set a flag(boolean), if a user've clicked on their referral link.<... | Building a referral system using Node/React/MongoDB | node.js|reactjs|mongodb|redux | 0 | 308 | 1 | 72,153,556 | 72,153,556 | 0 | true | 2022-05-07T14:17:04.563Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Building a referral system using Node/React/MongoDB<p>I am making a referral system for my website. I have two schema one is user and other is referral. The ... |
72,147,997 | execution script for several ID - loop?<p>I'm downloading ID from localStorage.getItem(1,22,3,14....).
I want every single ID to be executed in jQuery (if it exists on the website).
I can execute the code for one ID, but I don't know what to do to make each ID after the decimal point executed. I try so but it doesn't p... | <ol>
<li>Split your string into an array using the <code>split</code> function.</li>
<li>Loop through your ids and process each id in turn.</li>
</ol>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettypri... | execution script for several ID - loop? | javascript|html|jquery|dom | 0 | 36 | 1 | 72,148,077 | 72,148,077 | 0 | true | 2022-05-06T22:32:41.433Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
execution script for several ID - loop?<p>I'm downloading ID from localStorage.getItem(1,22,3,14....).
I want every single ID to be executed in jQuery (if it... |
72,210,688 | iOS - Google maps not showing all the waypoints added in browser. Working fine in google maps app and browser(with desktop site)<p>I'm working with an app which needs to pass source, in between waypoints and destination in google maps.</p>
<p>I'm first checking whether google maps app can be opened or not. If yes, I op... | <p>I think that Google maps in the mobile browser can only have 2 additional waypoints. It doesn’t allow you to add more manually. If you try setting it up yourself, rather than passing in a route you will find that you are unable to set up any more than 2 additional waypoints.</p>
<p>Here is me me adding a 2nd waypoin... | iOS - Google maps not showing all the waypoints added in browser. Working fine in google maps app and browser(with desktop site) | ios|swift|google-maps | 0 | 96 | 1 | 72,211,226 | 72,211,226 | 0 | true | 2022-05-12T05:54:31.247Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
iOS - Google maps not showing all the waypoints added in browser. Working fine in google maps app and browser(with desktop site)<p>I'm working with an app wh... |
71,953,626 | yolov4-darknet, how to show full loss/mAP graph if the training is several times<p><a href="https://i.stack.imgur.com/poiab.png" rel="nofollow noreferrer">chart_yolov4_custom, this is my trained loss/mAP graph</a></p>
<p>Why graph is showing only part I think is because I restart training in 2、3 times, so I think this ... | <p>It happens because you trained the model several times. There is no solution except you train the model once again but without interruption.</p> | yolov4-darknet, how to show full loss/mAP graph if the training is several times | object-detection|loss|yolov4|training | 0 | 278 | 1 | 72,483,880 | 72,483,880 | 0 | true | 2022-04-21T11:25:06.117Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
yolov4-darknet, how to show full loss/mAP graph if the training is several times<p><a href="https://i.stack.imgur.com/poiab.png" rel="nofollow noreferrer">ch... |
72,166,841 | How to achieve a "peer-to-peer" connection with TCPClient/TCPListener in System.Net.Sockets C# (NAT Traversal, no portforward, hole punching)<h2>Preface:</h2>
<p>This question is acting as an aggregation of what I've learned so far about this subject. It seems to not be discussed that much (maybe because it's not used ... | <h3>I did some research and found my own answers, but now I want to share them here with others.</h3>
<p>This post is VERY LONG, so look at the headings to figure out what you want to read first. I've updated this post over multiple days. And added new things, some things may be repeated for each main heading.</p>
<p>B... | How to achieve a "peer-to-peer" connection with TCPClient/TCPListener in System.Net.Sockets C# (NAT Traversal, no portforward, hole punching) | c#|sockets|networking|tcp|system.net.sockets | 0 | 234 | 1 | 72,280,113 | 72,280,113 | 0 | true | 2022-05-09T03:56:42.790Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to achieve a "peer-to-peer" connection with TCPClient/TCPListener in System.Net.Sockets C# (NAT Traversal, no portforward, hole punching)<h2>Preface:</h2... |
72,038,793 | How to cbind two series of array in to one dataframe by for loop in R<p>I have two series of array, pan1,pqn2,,,pn30 and read1,read2,,,read30, I want to cbind them into one dataframe with colnames like pan1,read1,pan2,read2,,,pan30,read30 by a for loop in R, how should I do? Here's my try but doesn't work</p>
<pre><cod... | <p>one solution in base R:</p>
<p>generate vector of <code>objects</code>' names observing the pattern pan1, read1, ..., pan30, read30</p>
<pre><code>objects_to_bundle <- as.vector(matrix(c(objects(pattern = '^pan*'),
objects(pattern = '^read*')
... | How to cbind two series of array in to one dataframe by for loop in R | r|for-loop | 0 | 19 | 1 | 72,039,151 | 72,039,151 | 0 | true | 2022-04-28T06:12:16.360Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to cbind two series of array in to one dataframe by for loop in R<p>I have two series of array, pan1,pqn2,,,pn30 and read1,read2,,,read30, I want to cbin... |
72,172,528 | Import a props since an other file for a component ReactJs<p>i have a question about the range of the props. I would in my App.js just call the component with 2 props (just below) and use those props in my other file "PrimaryButton.js".</p>
<pre><code>function App() {
return (
<div className="Ap... | <p>To utilize props in your case, it would look like this:</p>
<pre><code>import './PrimaryButton.css';
import React from 'react';
class PrimaryBouton extends React.Component {
render() {
const { title, type } = this.props;
return (
<button className={type}>
<span>{title}</span&... | Import a props since an other file for a component ReactJs | reactjs | 0 | 45 | 1 | 72,172,610 | 72,172,610 | 0 | true | 2022-05-09T13:09:02.803Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Import a props since an other file for a component ReactJs<p>i have a question about the range of the props. I would in my App.js just call the component wit... |
72,142,760 | Defect in linked list in Python<pre><code>class Node:
def __init__(self,data):
self.data=data
self.next=None
head=Node(5)
trys=head
trys=trys.next
trys=Node(7)
print(head.next.data)
</code></pre>
<p>Here print would give error. Can you explain why?</p> | <p>The line <code>trys=head</code> creates a new variable which is pointed to <code>head</code>.</p>
<p>The line <code>trys=trys.next</code> re-assigns the variable <code>trys</code> to <code>head.next</code>.</p>
<p>The line <code>trys=Node(7)</code> re-assigns <code>trys</code> to <code>Node(7)</code>. But the varia... | Defect in linked list in Python | python | 0 | 39 | 1 | 72,142,996 | 72,142,996 | 0 | true | 2022-05-06T14:02:35.487Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Defect in linked list in Python<pre><code>class Node:
def __init__(self,data):
self.data=data
self.next=None
head=Node(5)
trys=he... |
72,196,446 | Flutter pagination not work. I can not load more data<p>i tried to load more data when scroll. But loadMore function not work. When debugging it stop loadMore function and Scroll not working. Can anyone help me?. I did not find a soluton. Why loadMore not work? What I want to do is load more data when scroll end, page ... | <p>I use this method for pagination in my projects:
First you get the total page and current page in your response like this:</p>
<pre><code>{
"success": true,
"code": 200,
"result":[your response],
"pageNumber": 0,
"totalPage": 0
}
</code></pre>
<p>And in you... | Flutter pagination not work. I can not load more data | android|ios|flutter|dart|flutter-test | 0 | 228 | 1 | 72,196,953 | 72,196,953 | 0 | true | 2022-05-11T06:38:51.170Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Flutter pagination not work. I can not load more data<p>i tried to load more data when scroll. But loadMore function not work. When debugging it stop loadMor... |
72,174,894 | PHP not echoing variables when print_r does<p>I'm not sure exactly what is going on but when a user clicks a submit button on an html page and the php script runs I get the print out from the print_r statement, but if I print a variable out with the echo statement, the value isn't returned. I've just ported the webpag... | <p>Here is an example I regress back to the original answer of needing just quotes around minAcres. As a proof of concept i filled in post array with the beginning few values from your screen shot. minAcres = 0. Output = '0'. Maybe your output has been formatted to not show the 0 but show blank/empty</p>
<pre><code><... | PHP not echoing variables when print_r does | php | 0 | 104 | 1 | 72,175,053 | 72,175,053 | 0 | true | 2022-05-09T15:58:12.103Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
PHP not echoing variables when print_r does<p>I'm not sure exactly what is going on but when a user clicks a submit button on an html page and the php script... |
72,173,825 | How to perform the indexing for xpath in cypress automation?<p>I want to make common function in cypress automation for that, I want to use the locators and xpath to find the element but I am facing issue using indexes in xpath cypress.</p>
<p>In selenium automation, it is easy to create parameterized xpath but in cypr... | <p>Cypress does not support xpath directly. You have to use the <code>xpath</code> plugin. See <a href="https://www.npmjs.com/package/cypress-xpath" rel="nofollow noreferrer">here</a> for more details on how to add this plugin to your project.</p>
<p>After that, you will be able to call the <code>xpath</code> command.
... | How to perform the indexing for xpath in cypress automation? | selenium|selenium-webdriver|automation|cypress|cypress-component-test-runner | 0 | 154 | 1 | 72,177,096 | 72,177,096 | 0 | true | 2022-05-09T14:40:41.083Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to perform the indexing for xpath in cypress automation?<p>I want to make common function in cypress automation for that, I want to use the locators and ... |
72,206,671 | In JavaScript, retrieve the value and performed the addition after that want to return the value after the for loop in cypress automation?<pre><code>verifyActiveInterfacesViaConnectionStatus() {
var sum = 0
var i;
for (i = 1; i <= 5; i++) {
cy.xpath(`(//*[name()='g' and @class ='h... | <p>Cypress commands are asynchronous.
<code>cy.log</code> captures the <code>sum</code> value <em>before</em> the first <code>xpath</code> command gets really executed.
To synchronize access to the <code>sum</code> you can use a then callback:</p>
<pre class="lang-js prettyprint-override"><code>verifyActiveInterfacesVi... | In JavaScript, retrieve the value and performed the addition after that want to return the value after the for loop in cypress automation? | selenium|selenium-webdriver|automated-tests|cypress|cypress-component-test-runner | 0 | 40 | 1 | 72,207,212 | 72,207,212 | 0 | true | 2022-05-11T19:31:49.887Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
In JavaScript, retrieve the value and performed the addition after that want to return the value after the for loop in cypress automation?<pre><code>verifyAc... |
72,151,451 | Delay page reload only in JS when form is validated<p>Hope you're well ;)</p>
<p>My problem:</p>
<p>In a form, I would like, when it's validated, to apply a delay of 3 seconds to the click before sending and reloading the page in order to show a validation message.
Here is the code:</p>
<p><div class="snippet" data-lan... | <p>It's because you're using <code><input type="submit"></code>. Submit will reload the page based on your provided action url in the tag.</p>
<p>Simply switch your input type to <code>button</code> and handle the reload via your JS code!</p> | Delay page reload only in JS when form is validated | javascript|forms|delay | 0 | 43 | 2 | 72,151,637 | 72,151,637 | 0 | true | 2022-05-07T10:02:09.617Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Delay page reload only in JS when form is validated<p>Hope you're well ;)</p>
<p>My problem:</p>
<p>In a form, I would like, when it's validated, to apply a ... |
72,153,494 | transforming a date in Month day, YEAR format to YYYY-MM-DD format?<p>Is there a way to reformat a date using <code>.replace</code> and a regex? or a series of them?</p>
<p>for example I would like to turn <code>May 4, 1981</code> into <code>1981-May-04</code>... this would be good enough for my needs.</p>
<p>but even ... | <p><code>new Date('May 4, 1981').toLocaleDateString('en-CA')</code>
outputs
'1981-05-04'</p>
<h2>toLocaleDateString is pretty powerful - check it out: <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleDateString" rel="nofollow noreferrer">https://developer.mozilla.or... | transforming a date in Month day, YEAR format to YYYY-MM-DD format? | javascript | 0 | 39 | 1 | 72,153,544 | 72,153,544 | 0 | true | 2022-05-07T14:35:45.110Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
transforming a date in Month day, YEAR format to YYYY-MM-DD format?<p>Is there a way to reformat a date using <code>.replace</code> and a regex? or a series ... |
72,161,424 | Run a code after 10s if a variable didn't change<p>I'm making a game for a discord bot that use the Discord.js API and I try to run a code after 10s if the variable playing (true/false) didn't change (to avoid a first person finish his game and a second person launch a new game and get time's up after a few seconds), s... | <p>Just add an if condition inside the setTimeout callback to check if they're still playing and only then end the game.</p>
<pre><code>const globalGameTimeout = null;
...
if(message.content === "?guess"){
playing = true;
globalGameTimeout = setTimeout(function(){
if (playing) {
message.reply(... | Run a code after 10s if a variable didn't change | javascript|discord.js | 0 | 47 | 1 | 72,161,500 | 72,161,500 | 0 | true | 2022-05-08T13:20:42.237Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Run a code after 10s if a variable didn't change<p>I'm making a game for a discord bot that use the Discord.js API and I try to run a code after 10s if the v... |
72,163,652 | Search bar in react works, but experiencing very strange behaviour<p>In a component when an input is provided it dispatches the input to a reducer</p>
<pre><code>const changeSearchTerm = (e) => {
setSearchTerm(e.target.value)
dispatch(userActions.searchByName(searchTerm));
}
</code></pre>
<p>Then the reduc... | <p>From what I can tell, it only works after the second input because of this block:</p>
<pre><code>const changeSearchTerm = (e) => {
setSearchTerm(e.target.value)
dispatch(userActions.searchByName(searchTerm));
}
</code></pre>
<p>State setters like <code>setSearchTerm</code> are actually <a href="https://... | Search bar in react works, but experiencing very strange behaviour | javascript|reactjs|react-redux | 0 | 44 | 1 | 72,163,816 | 72,163,816 | 0 | true | 2022-05-08T17:42:03.863Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Search bar in react works, but experiencing very strange behaviour<p>In a component when an input is provided it dispatches the input to a reducer</p>
<pre><... |
72,165,276 | typescipt and react searchbar api fetch<p>I'm trying to fetch the author's name in this search bar component. the idea is to fetch the author's name in the search bar and display the author's picture with the author's name. but it's not working for me. Can someone help and explain why this is not working. Thank you.</p... | <p>Your url is wrong.</p>
<pre><code>`https://picsum.photos/v2/?=${query}`
</code></pre>
<p>This goes to a bad page. Can you go to picsum.photos and use their available API endpoints accordingly, such as their list endpoint.</p>
<p><code>https://picsum.photos/v2/list</code></p>
<p>It looks like there's only a limited n... | typescipt and react searchbar api fetch | reactjs|typescript|api | 0 | 297 | 1 | 72,165,315 | 72,165,315 | 0 | true | 2022-05-08T21:40:32.913Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
typescipt and react searchbar api fetch<p>I'm trying to fetch the author's name in this search bar component. the idea is to fetch the author's name in the s... |
72,183,641 | how to add support RtL into viewPager Kotlin?<p>I want to add or apply :</p>
<pre><code>viewPager?.rotationY = 180F
</code></pre>
<p>to my view pager just when app language is setted to fa or ps from en. or prevent applying that when language is en.
I used <code>viewPager?.rotationY = 180F</code> in whole app but I wan... | <p>you can use <code>Locale.getDefault().getLanguage()</code> for getting information what language is set. wrap it in some <code>if</code> statement and put in <code>onCreate</code> and/or in <code>onResume</code> (as lang may change during <code>Activity</code>s lifecycle - app homed, language changed, app bring back... | how to add support RtL into viewPager Kotlin? | android|kotlin|android-viewpager | 0 | 42 | 1 | 72,184,443 | 72,184,443 | 0 | true | 2022-05-10T09:15:16.077Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to add support RtL into viewPager Kotlin?<p>I want to add or apply :</p>
<pre><code>viewPager?.rotationY = 180F
</code></pre>
<p>to my view pager just wh... |
72,182,451 | useEffect Object dependency infinite loop - ReactJS<p>I have a State in Context with Object. I am running a <code>async</code> function in the <code>useEffect</code> and passing my object state as <code>dependency</code>.</p>
<blockquote>
<p>I passed the state object as dependency because i want to re-render
the compon... | <p>I forgot that when re-rendering happens, it also runs <code>useEffect</code> obviously and it causes <code>setState</code> again and again.<br>
I managed to fix this by creating a state named <code>initialItemCount</code> with <code>0</code> initial value. I am checking if that state value is 0 then run <code>addTex... | useEffect Object dependency infinite loop - ReactJS | javascript|reactjs|object|react-hooks|use-effect | 0 | 245 | 2 | 72,183,886 | 72,183,886 | 0 | true | 2022-05-10T07:44:14.127Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
useEffect Object dependency infinite loop - ReactJS<p>I have a State in Context with Object. I am running a <code>async</code> function in the <code>useEffec... |
72,151,400 | CAGR Calculation for different variables in R<p>I was inspired by these 2 photos. First I wanted to get a single value for each So I grouped them together and averaged them for each year.</p>
<p><a href="https://i.stack.imgur.com/Dw19v.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Dw19v.jpg" alt="... | <p>Try this ...</p>
<pre class="lang-r prettyprint-override"><code>library(tidyverse)
library(scales)
#>
#> Attaching package: 'scales'
#> The following object is masked from 'package:purrr':
#>
#> discard
#> The following object is masked from 'package:readr':
#>
#> col_factor
growt... | CAGR Calculation for different variables in R | r|function | 0 | 63 | 1 | 72,151,688 | 72,151,688 | 0 | true | 2022-05-07T09:53:50.357Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
CAGR Calculation for different variables in R<p>I was inspired by these 2 photos. First I wanted to get a single value for each So I grouped them together a... |
72,148,161 | How to call substring() with variables?<p>How to call the <code>substring()</code> function with variables for the <code>start</code> & <code>count</code> parameters? Below example code is not working.</p>
<pre class="lang-sql prettyprint-override"><code>DO
$$
declare
v_idx numeric(3);
v_ch char(1);
v_... | <p>This works:</p>
<pre class="lang-sql prettyprint-override"><code>DO
$$
DECLARE
_string text := 'My String';
_start int := 1; -- integer!
_count int := 1; -- integer!
_substr text;
BEGIN
FOR _start IN 1 .. length(_string)
LOOP
_substr := substring(_string, _start, _coun... | How to call substring() with variables? | postgresql|substring|plpgsql | 0 | 137 | 1 | 72,149,306 | 72,149,306 | 0 | true | 2022-05-06T22:59:38.687Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to call substring() with variables?<p>How to call the <code>substring()</code> function with variables for the <code>start</code> & <code>count</code... |
72,198,872 | try catch and throw - still get "unreported exception"<p>About the Java code below, NetBeans complains about the <code>throw</code> statement, stating there is an "unreported exception <code>IOException</code>", even though I am already catching it...</p>
<pre><code>public class MyClass {
public stat... | <p><strong>In Java there are two types of Exceptions :</strong></p>
<blockquote>
<p>1- Checked Exceptions</p>
<p>2- Unchecked Exceptions</p>
</blockquote>
<p><strong>Handle</strong> : using a try catch block : the line that may cause the exception should be in the try block , the catch block run when the exception thro... | try catch and throw - still get "unreported exception" | java|exception|netbeans | 0 | 76 | 2 | 72,199,400 | 72,199,400 | 0 | true | 2022-05-11T09:47:24.983Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
try catch and throw - still get "unreported exception"<p>About the Java code below, NetBeans complains about the <code>throw</code> statement, stating there ... |
72,187,042 | Ratchet client event loop wait for finish<p>I have the following test php code:</p>
<pre class="lang-php prettyprint-override"><code>use React\EventLoop\Loop;
$loop = Loop::get();
$reason = "unknown";
\Ratchet\Client\connect('wss://demo.piesocket.com/v3/channel_1?api_key=VCXCEuvhGcBDP7XhiJJUDvR1e1D3eiVjgZ9VR... | <p>Add</p>
<pre class="lang-php prettyprint-override"><code>$loop->run();
</code></pre>
<p>before the echo, the run() will block the thread until it has finished.
So the echo will be printed at the end of the script and the $reason will be filled in as expected.</p>
<p>The Loop::get() function has this comment:</p>
... | Ratchet client event loop wait for finish | php|ratchet|reactphp | 0 | 117 | 1 | 72,191,880 | 72,191,880 | 0 | true | 2022-05-10T13:14:48.587Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Ratchet client event loop wait for finish<p>I have the following test php code:</p>
<pre class="lang-php prettyprint-override"><code>use React\EventLoop\Loop... |
72,226,208 | for salt and hashing passwords i used Bcrypt method but its showing , error = new Error('data and salt arguments required');<p>for salt and hashing passwords i used Bcrypt method but its showing ,
error = new Error('data and salt arguments required');
i think my code have the problem please i need help please;
eCommerc... | <p>Thank you, I got the solution. The problem in the <code>user-helpers.js</code>.</p>
<p><code>user-helpers.js</code></p>
<pre><code>
const bcrypt = require('bcrypt')
module.exports={
doSignup:(userData)=>{
return new Promise (async(resolve,reject)=>{
... | for salt and hashing passwords i used Bcrypt method but its showing , error = new Error('data and salt arguments required'); | javascript|node.js|bcrypt|helper | 0 | 169 | 2 | 72,249,636 | 72,249,636 | 0 | true | 2022-05-13T07:56:03.350Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
for salt and hashing passwords i used Bcrypt method but its showing , error = new Error('data and salt arguments required');<p>for salt and hashing passwords... |
72,157,956 | Kotlin (android studio) - changing tab by clicking doesn't change button on selected fragment, where swiping to the tab works<p>I'm new to Kotlin and Android programming.</p>
<p>I Have 2 tabs using TabLayout and ViewPager2.
In my main activity xml I have edit text widget. When I enter text and push ENTER the program ne... | <p>Maybe you need some changes in the adapter code of viewPager
Let me share my code Here
With tab layout and fragment</p>
<p>Here is the TabAdapter code</p>
<pre><code>class TabAdapter : FragmentStateAdapter {
var fragments = arrayListOf<Fragment>()
constructor(fragmentActivity: FragmentActivity, fragm... | Kotlin (android studio) - changing tab by clicking doesn't change button on selected fragment, where swiping to the tab works | android|kotlin|android-fragments|tablayout | 0 | 247 | 1 | 72,158,035 | 72,158,035 | 0 | true | 2022-05-08T03:59:44.057Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Kotlin (android studio) - changing tab by clicking doesn't change button on selected fragment, where swiping to the tab works<p>I'm new to Kotlin and Android... |
72,159,869 | How to manage Login Validation with Room in Kotlin?<p>I'm trying to make work the Login Validation form, but the program stops then reaches the second <strong>if</strong>, and I have <em>Invalid email</em> output. Run is clear and out of mistakes. Can't figure out what I'm doing wrong and why <strong>emailList</strong>... | <pre><code>fun getUserEmail(email: String): User? {
var checker: User? = null
viewModelScope.launch(Dispatchers.IO) {
checker = repository.getUserEmail(email)
}
return checker
// Will return null always because this is not waiting to assign value by above repository method
}
</code></pre>
<... | How to manage Login Validation with Room in Kotlin? | android|sqlite|kotlin|authentication|android-room | 0 | 268 | 1 | 72,159,945 | 72,159,945 | 0 | true | 2022-05-08T09:57:09.683Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to manage Login Validation with Room in Kotlin?<p>I'm trying to make work the Login Validation form, but the program stops then reaches the second <stron... |
72,171,789 | Firebase setting value from another key<p>I have a firebase function that sets two values to zero. Is there a way to set the value of "lastDaily" to whatever the value of "click" is before setting click to 0?</p>
<pre><code>exports.dailyReset = functions.pubsub.schedule("01 0 * * *")
.... | <p>The following should do the trick (untested):</p>
<pre><code>exports.dailyReset = functions.pubsub.schedule("01 0 * * *")
.timeZone("Europe/London")
.onRun(async (context) => {
const snapshot = await dbCon.get();
const promises = [];
s... | Firebase setting value from another key | javascript|firebase|firebase-realtime-database|google-cloud-functions | 0 | 34 | 1 | 72,172,042 | 72,172,042 | 0 | true | 2022-05-09T12:11:10.157Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Firebase setting value from another key<p>I have a firebase function that sets two values to zero. Is there a way to set the value of "lastDaily" t... |
72,182,960 | Netlogo: move to a specific patch<p>I am gonna ask a simple question. I have workers and patches. Workers want to go to a specific patch, labeled by an id. I tried the following code, but it does not work. Can someone help me? Thanks</p>
<pre><code>workers-own[selected-area]
patches-own [id]
ask workers [
move-to one-... | <p>In your example you have two important variables. <code>selected-area</code>, which is a turtles-variable, and <code>id</code>, which is a patch-variable.
Each agent (patch or turtle) can access its own variable, but not those of the others. The problem here, is that you ask the patches to compare <code>id</code> to... | Netlogo: move to a specific patch | netlogo|move|patch | 0 | 40 | 1 | 72,183,281 | 72,183,281 | 0 | true | 2022-05-10T08:24:51.790Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Netlogo: move to a specific patch<p>I am gonna ask a simple question. I have workers and patches. Workers want to go to a specific patch, labeled by an id. I... |
72,223,780 | Unable to retrieve the correct value from a list of object within object<p>I am quite new to javascript and I've been struggling with this type of challenge. I understand the problem and implement a logic to solve the issue but I am unable to display the values correctly.</p>
<p>Can someone take a look at my code and m... | <p>You should change <code>results = elm[field];</code> to <code>if (elm[field]) { results[field] = elm[field]; results.name = elm.name; }</code>,
this because you need to verify that property exist. You should also change <code>return results; </code> by <code>return Object.keys(results).length ? results : "Not f... | Unable to retrieve the correct value from a list of object within object | javascript|object|debugging | 0 | 36 | 1 | 72,224,023 | 72,224,023 | 0 | true | 2022-05-13T02:13:46.080Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Unable to retrieve the correct value from a list of object within object<p>I am quite new to javascript and I've been struggling with this type of challenge.... |
72,210,878 | Error occurred while implement livekit_client: ^0.5.9 package #flutter<p>error:</p>
<p>FAILURE: Build failed with an exception.</p>
<ul>
<li>What went wrong:
A problem occurred configuring project ':livekit_client'.</li>
</ul>
<blockquote>
<p>Could not load compiled classes for build file 'C:\src\flutter.pub-cache\host... | <p>How I solved my problem by following the below method:</p>
<p>remove the problem making package from
/.pub-cache/hosted/pub.dartlang.org</p>
<p>Run flutter pub get
change this:</p>
<p>distributionUrl=https://services.gradle.org/distributions/gradle-5.6.2-all.zip
to this:</p>
<p>distributionUrl=https://services.gradl... | Error occurred while implement livekit_client: ^0.5.9 package #flutter | android|flutter|gradle | 0 | 50 | 1 | 72,211,290 | 72,211,290 | 0 | true | 2022-05-12T06:17:31.927Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Error occurred while implement livekit_client: ^0.5.9 package #flutter<p>error:</p>
<p>FAILURE: Build failed with an exception.</p>
<ul>
<li>What went wrong:... |
72,218,164 | URLSearchParams not parsing query string<p>Using <code>react-router-dom</code> version 5.</p>
<p>Some component, rendered when matching a <code><Route /></code>:</p>
<pre><code>...
const { search } = useLocation();
const params = new URLSearchParams(search);
useEffect(() => {
console.log(search); // &q... | <p>You are not using URLSearchParams as you should. You are getting URLSearchParams object and if you want to get it as a string, you should log <code>params.toString()</code></p>
<p>Check out these links:</p>
<ol>
<li><a href="https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams/URLSearchParams" rel="nofol... | URLSearchParams not parsing query string | reactjs|react-router-dom|urlsearchparams | 0 | 87 | 1 | 72,218,300 | 72,218,300 | 0 | true | 2022-05-12T15:15:42.733Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
URLSearchParams not parsing query string<p>Using <code>react-router-dom</code> version 5.</p>
<p>Some component, rendered when matching a <code><Route /&g... |
72,155,497 | S3AsyncClient resume multipart upload after application restart<p>I'm using <code>S3AsyncClient</code> client in Java to upload a big file using multipart upload.</p>
<p>If the application restarts during upload, a new <code>S3AsyncClient</code> instance is created with a new <code>uploadId</code>.</p>
<p>Is it possibl... | <blockquote>
<p>Is it possible to complete a multipart upload with a new <code>uploadId</code>?</p>
</blockquote>
<p>No, you require the same <code>uploadId</code> used to first initiate the multipart upload.</p> | S3AsyncClient resume multipart upload after application restart | java|amazon-web-services|amazon-s3|multipart-upload | 0 | 56 | 1 | 72,155,982 | 72,155,982 | 0 | true | 2022-05-07T18:46:26.520Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
S3AsyncClient resume multipart upload after application restart<p>I'm using <code>S3AsyncClient</code> client in Java to upload a big file using multipart up... |
72,186,255 | Resolve php error : Trying to access array offset on value of type bool<p>I'm trying to insert SQL response into .csv file, but when I execute my code, I got this error : Trying to access array offset on value of type bool</p>
<p>This is my code :</p>
<pre class="lang-php prettyprint-override"><code>$fh = fopen("f... | <p><code>mysqli_stmt::fetch</code> doesn't return a row of result, you need bind columns to variables first.</p>
<pre><code>$stmt->bind_result($perso1, $relation, $perso2, $idnat, $id_perso1, $id_perso2);
</code></pre>
<p>Then each time you fetch a row, these variables will be filled with data.</p>
<pre><code>while(... | Resolve php error : Trying to access array offset on value of type bool | php | 0 | 66 | 1 | 72,187,275 | 72,187,275 | 0 | true | 2022-05-10T12:23:36.700Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Resolve php error : Trying to access array offset on value of type bool<p>I'm trying to insert SQL response into .csv file, but when I execute my code, I got... |
72,169,761 | Progress bar with intervals<p>I am trying to create a progress bar with steps and a play/pause button.</p>
<p>I am having trouble with creating the play/pause button but the case is that onload progress bar should not be filling, only after pressing the play button.</p>
<p>The second case I can't figure out is when the... | <p>This is an implementation of a progress bar having some defined checkpoints.</p>
<p>The defined checkpoints hold the percentage value of each one and its label to show in the ruler.</p>
<p>After pressing the play button, the button label toggles to "pause" and the progress bar will begin advancing. If the ... | Progress bar with intervals | javascript|jquery|animation|progress | 0 | 739 | 1 | 72,171,612 | 72,171,612 | 0 | true | 2022-05-09T09:29:57.357Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Progress bar with intervals<p>I am trying to create a progress bar with steps and a play/pause button.</p>
<p>I am having trouble with creating the play/paus... |
72,191,968 | Convert JavaScript array data to json file<p><strong>So I have this array with different links</strong></p>
<pre><code>const urls = ['myurl.com', 'localhost.com'... etc]
</code></pre>
<p><strong>In the for loop I want to create an object like so, it should basically create a new object for every URL, and then pass the ... | <p>I tried this code on Chrome and it works correctly plus it correctly format the json data now, instructing JSON.stringify to use 4 spaces indentation.</p>
<p>It won't work in the snippet, but it will if you save it in your own file. I did it inside the chrome developer tools in the Sources tab as a snippet and as so... | Convert JavaScript array data to json file | google-chrome|manifest|chrome-declarativenetrequest | 0 | 88 | 1 | 72,192,114 | 72,192,114 | 0 | true | 2022-05-10T19:22:53.747Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Convert JavaScript array data to json file<p><strong>So I have this array with different links</strong></p>
<pre><code>const urls = ['myurl.com', 'localhost.... |
72,190,592 | nvim started as desktop application | :checkhealth - commands not available<p>When I start neovide from my applications and run :checkhealth I get errors that node and other commands are not available. But when I start it from my terminal there is no error for those commands. I tried to copy and modify the neovide desk... | <p>TL:DR; add a path variable</p>
<p>Depending on your configuration, nvim will need to know the environment to run some executables (like it is with node in your example). An easy solution is to add the path variable to the exec command in the according .desktop file. I remember that I had the same issue with node not... | nvim started as desktop application | :checkhealth - commands not available | linux|desktop-application|neovim | 0 | 74 | 1 | 72,190,663 | 72,190,663 | 0 | true | 2022-05-10T17:19:22.010Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
nvim started as desktop application | :checkhealth - commands not available<p>When I start neovide from my applications and run :checkhealth I get errors tha... |
72,145,592 | Laravel Store , corrupted or not all are saved on database<pre><code> public function patient_aprrovedischarge(Request $request, $id)
{
//get patient details
$patientDischarge = DischargedPatients::where('id', '=', $id)->first();
//find patient update to DISCHARGE pending
$updat... | <p><strike>You are trying to save same record twice</strike>, basically <code>$patientDischarge</code> and <code>$dischargepatient</code> are same records.</p>
<pre class="lang-php prettyprint-override"><code>
public function patient_aprrovedischarge(Request $request, $id)
{
//get patient details
$patientDischa... | Laravel Store , corrupted or not all are saved on database | php|laravel|controller | 0 | 23 | 1 | 72,145,964 | 72,145,964 | 0 | true | 2022-05-06T17:52:45.883Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Laravel Store , corrupted or not all are saved on database<pre><code> public function patient_aprrovedischarge(Request $request, $id)
{
//get pat... |
72,182,819 | r problem to plot a linechart with multiple columns of dataframes as lines<p>I have a very simple dataframe called comparison_word_avg:</p>
<pre><code> index uniform blur man_check_no_blur
1 1 94.71% 93.83% 91.96%
2 2 87.14% 86.08% 83.04%
3 3 81.29% 88.95% 80.36%
4 ... | <p>Because they have a percentage sign in them, your columns are stored in character format, not numeric format. This means <code>ggplot</code> does not know that you want them treated like numbers. To convert them, we can strip away the percentage sign, convert to numeric, then divide by 100 to get the percentages as ... | r problem to plot a linechart with multiple columns of dataframes as lines | r|ggplot2|data-visualization|linechart | 0 | 25 | 1 | 72,182,969 | 72,182,969 | 0 | true | 2022-05-10T08:15:50.363Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
r problem to plot a linechart with multiple columns of dataframes as lines<p>I have a very simple dataframe called comparison_word_avg:</p>
<pre><code> inde... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.