Latest Questions

Plotting value from matching complete pairs in rows

I have data of drug concentrations (DV) that include a parent drug and its metabolite, coded DVID 1 and 2, respectively. They are provided to me as separate ro

Generic RenderFragment not allowing parameters

I create a component PopupForm which take PopupFormAvatar component as parameter [Parameter] public RenderFragment PopupFormAvatar { get; set; } [Parameter] pu

Do all ESP32 pin can be used when using wifi?

lately I build a project which is use relay and several sensor, I also use wi-fi to connect it to internet, but when I try to code digital write use some pin, i

How to filter excel file using three or more criteria and copy the filtered data to another sheet using powershell

I have a excel table as below: excel data I want to filter this file based on three criteria i.e. $criteria = "Rice","Vegetables","Butter" and copy the filtered

Django customUser models

I have faced two or three issues with django customuser model. The first one being the skills models. I wanted to add the Skills in the custom user, realized th

iOS 15 only view modifier causes crash on iOS 14 even with if #available(iOS 15.0, *)

I'm using SwiftUI's drag & drop modifiers. Since, iOS 15 gives an option to customise the onDrag modifier with a preview I'm using it as shown below. Issue:

Printing multiplication table using arrays and nested for loops

I am working on an assignment to create a multiplication table using a 2D array. This is what I came up with. 'use strict'; window.addEventListener('load',

How to create a global string in a vue (webpack) project

In my vue project I have a default image that should show up in places around the app when an image is missing or hasn't been uploaded yet. I have various class

Different behaviors between C and Rust code snippets

I have a C code snippet which uses pipe() and fork() to communicate between parent and child process. I want to replicate it in Rust. For the POSIX APIs used in

CS0120: An object reference is required for the nonstatic field, method, or property 'foo'

Consider: namespace WindowsApplication1 { public partial class Form1 : Form { public Form1() { InitializeComponent();

How to configure maxDegreeOfParallelism for cosmosdb in Springboot?

I want to configure the CosmosQueryRequestOptions.maxDegreeOfParallelism while using the CosmosRepository. I didn't find any documentation around it. This blog

How to use Turborepo for an existing react app created with Create React App in order to make it a monorepo?

I have a fun project made with create react app. I want to convert the same application to a browser extension. This idea forces me to make the project a mono r

Pygoat docker is broken

Hi I am wondering why can't I connect to the pygoat site while it is running on docker this is the repo link https://github.com/JustinDPerkins/pygoat-tm I also

Drawing with drawString doesn't look good

The result of drawString with the same font and size in java The appearance is different when drawn with the same font and size in a painter (or word). Drawing

button doesn't add to cart - WooCommerce

I'm not sure why this is not allowing me to add to the cart. I have access to the global product but it's not capturing the ID to add to cart <?php /**

Defining Month Time Partition using Teradata Data Transfer Service Custom Schema

I am looking for a way to define a Teradata Data Transfer custom schema that implements a month based date partition. The documentation only provides a method

Bug in Microsoft x64 compiler for signed/unsigned mismatch warnings?

Consider this piece of code: #include <iostream> #include <vector> #include <cstdint> int main() { std::vector<int> a{ 10, 11, 12, 13

How to find where an object is located in a list?

i have a list "players" and i want to find if my player is players[0] or players[1] or whaterver. How do i do this?

TypeError: argument of type 'Message' is not iterable. Discord Python Bot

I get this error everytime a message is sent ive tried looking for solutions but havent found any here is the traceback: Traceback (most recent call last): Fi

Pytorch's autograd issue with joblib

There seems to be a problem mixing pytorch's autograd with joblib. I need to get gradient in parallel for a lot of samples. Joblib works fine with other aspects

React - Enzyme mount throwing regeneratorRuntime is not defined error

I am trying to test the following component: class SearchComp extends Component { constructor(props){ super(props);

Accumulating Doubles Into Bins via intrinsics

I have a vector of observations and an equal length vector of offsets assigning observations to a set of bins. The value of each bin should be the sum of all ob

Oracle SQL: dummy variable from 2 data sets

I have two data tables. They both have an employee id column and a sales quarter column, in addition to lots of other columns. The first, which ill call "Rost

Need a Click and Drag solution using Vanilla Javascript without jQuery

I have to do a click-and-drag solution for a background image in Vanilla Javascript for a project. I found this solution using jQuery in Codepen. Can anyone hel

Vue 3 - "Failed to resolve component" with child component

I have this SocialNetworks.vue component <template> <div class="socialNetworks"> <SocialLink to="https://twitter.com/" icon="twitter.svg" n

Ability to load component while axios

Is it possible to do the following: There is a spinner component. axios: method() { SPINNER (component) -- on axios.get('/shop', { params:

Two HTML Forms in one DJango views

I have two simple HTML forms on one page. I want to create Django view to submit multiple Django forms. I can submit form1 but I have no clue how to submit form

react-router-dom v6 StaticRouter context is not working

I'm trying to make SSR React web application. Everything works fine except staticContext. My server code is // IMPORTS const renderer = (req, store, context) =

While loop not terminating even after the 'return'

I am using the while loop to iterate through an array and trying to terminate the loop using the return (I tried foreach before which doesn't terminate for retu

Any short way to create a combinations of arrays with fixed length and sum?

For example: array = [4,0,0] The generated arrays have to be of a fixed length and sum of the array has to be also fixed. What would be the shortest and effici