title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
What is the correct, modern way to handle arbitrary text input in a custom control on Windows? WM_CHAR? IMM? TSF?
<p>I want to be able to support text input in a custom Windows control, just like the EDIT and rich edit controls already do, but not subclassing either of those. The control currently uses Direct2D and DirectWrite to draw text, and runs on Windows Vista SP1 with Platform Update or newer (I might change it to Windows 7...
3
1,139
nested defines in makefile
<p>I'm very new to creating makefiles, so this question might be trivial. If I'm using bad coding practices, I would appreciate to be pointed at it.</p> <p>I am trying to create a generic makefile that creates rules based on input variables. At the end of my posting is a "minimal" example.</p> <p>I got 2 problems.</p...
3
1,114
POST data from angular to node not working
<p>I am using angular to send data to node server but it is not working. I am not able to see my post data(input values in form) in my node post method. I need to get that data save in mongoDb but I don't know why I can't see the POST values sent by the front-end.</p> <p>I am not able to see my form data in node via c...
3
3,241
How to Upload Bitmap Images with Retrofit?
<p>In my App i need to enable the user to upload 6 images as max from gallery after resize the images to Bitmaps, i have finished the selecting and resizing part successfully as shown below code and store the results in array of bitmaps <strong>imageslist</strong> . My question is How to upload my bitmaps array using R...
3
1,193
How to make an iFrame inside bootstrap container-fluid class occupy screen width?
<p>I am trying to build ASP.NET website with Master page based on bootstrap framework. I need to fit one page containing an iFrame to occupy complete screen width. Currently it is leaving some space to the left and right (might be default 15px of container class which I have tried changing to 0 in bootstrap.css)</p> <...
3
2,205
Extracting two substrings with specific starting characters from a long string and concatenating them
<p>I am attempting to extract two pieces of information from a long string containing much more than I need. I have a tab-delimited .txt file with the following format repeated for 115,000 lines:</p> <pre><code>TRINITY_DN89_c0_g1_i1 blastx match_part 2 388 5.00e-73 + 1 Target=UniRef90_UPI0005D06956 2 388;...
3
1,206
Where does MQL4 / MQL5 implementation of originally C++ AVL Tree Parent node exhibit an issue?
<p>I dont know where I am having an issue, but I am getting a strange error in my AVL implementation, translated into <strong><code>MQL4/MQL5</code></strong> language.</p> <p>In failed case, I am getting into either</p> <ul> <li><strong>recursively pointing to same node</strong> problem</li> </ul> <p>or</p> <ul> <l...
3
7,387
Wpf change size of data inside gridView
<p>hello i have data in a gridView and i want to change the size of the data: i mean i want to resize the data who comes from a list in c#</p> <p>code:</p> <pre><code>&lt;Window x:Class="DadBussines.PL.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.micros...
3
1,131
BeautifulSoup & requests_html unable to find element
<p>I need to scrape information from this page: <a href="https://professionals.tarkett.co.uk/en_GB/collection-C001030-arcade/arcade-b023-2128" rel="nofollow noreferrer">https://professionals.tarkett.co.uk/en_GB/collection-C001030-arcade/arcade-b023-2128</a>.</p> <p>There are 6000+ of those pages I need to scrape. I rea...
3
2,016
How to centre 2 elements in a constraint layout, which have different heights
<p>I am trying to centre elements in a constraint layout, I could use a guide line to be centred and then place the image and textview up and below it, but image and textview are of different height so they would not be centred.</p> <p>any best approach on this please</p> <pre><code> &lt;androidx.constraintlayo...
3
1,540
Intent.ACTION_PICK FAILED BINDER TRANSACTION on Nested Fragment
<p>I need my users to select image from gallery to upload image to server. I've tried on an Activity and it works fine. But now I need the same codes on a child fragment (nested fragment). But this time, I always got this error when debugging. I even don't use any putExtra() into the intent.</p> <pre><code>I/Timeline:...
3
1,414
my alert size is not showing correctly in android?
<p>My alert width is too short.</p> <p>screenshot:</p> <p><a href="https://i.stack.imgur.com/Hk68C.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Hk68C.png" alt="enter image description here"></a></p> <p>Here is design xml:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;LinearLa...
3
1,925
How can I convert this untidy table header sorting code to well compact function?
<p>I have written a code snippet to sort my table headers in PHP/MySQL. The HTML of table headers along with PHP embedded code is given by:</p> <pre><code>&lt;tr&gt; &lt;th&gt;&lt;a href="?orderby=id&lt;?php if($orderby == '`post_id`' &amp;&amp; $order == 'asc') echo '&amp;order=desc'; else echo '&amp;order=asc'; ...
3
2,306
Why do I get an "ArrayIndexOutOfBounds" error in this program?
<p>I have written a program in which the user inputs the dimensions of a two-dimensional array, then the computer prints out the table with those dimensions and fills it with random integers from 0 to 9. Then, if there are four consecutive equal integers that appear anywhere in the table, the computer would return "Tru...
3
1,540
Calling multiple JSON data with Jquery Deferred
<p>I am trying to get multiple JSON data with deferred object. I have JSON files for individual days. In each individual day, I have data for points, lines and polygons. I have jQueryUI Sliders to visualise for individual days. For example, if the slider has value of 1, only the day1 data (points, lines and polygons) ...
3
3,144
Error retrieving data from Sqlite Android
<p>I'm getting a force close when I try to retrieve data from sqlite db and set it to text views. here's the fetch method:</p> <pre><code>public ArrayList&lt;Object&gt; getRow() { ArrayList&lt;Object&gt; list= new ArrayList&lt;Object&gt;(); Cursor cursor; String[] columns={PRIMARY_KEY,COLUMN_N...
3
2,870
how to identify submit() from javascript function and why it's not works
<p>I have a list of users that in the end of each line in the table I added two links("href"): one for "update" user and secend for "delete" user. So for enable that I added a call to javascript function that capture the ID of user and set another field to "true" and insert these values to some form that I created befo...
3
1,635
GoogleMapsDemo gives IllegalStateException
<p>I have did all steps which is give at google but lastly it give's this </p> <pre><code>errorCaused by: java.lang.IllegalStateException: The meta-data tag in your app's AndroidManifest.xml does not have the right value. Expected 4132500 but found 0. You must have the following declaration within the &lt;applicatio...
3
1,772
View Doesn't Open When I Try To Run My Program?
<p>I am following tutorials from this gentleman (<a href="https://www.youtube.com/watch?v=_NCw5S7PUXw" rel="nofollow">https://www.youtube.com/watch?v=_NCw5S7PUXw</a>) messing around in Java trying to make a Tower Defense game. I have finished the above video, and so far my code is as follows. I have it divided into thr...
3
1,628
Css nav submenu mobile don't work
<p>I'm building a nav menu with sub-menus with just CSS (media queries too) and html.</p> <p>It works fine visualy, but the problem is: On the mobile browser, When I click in any sub-menu, it won't work, sometimes it just redirect to the first menu address and sometimes it don't even redirect. On the computer browser ...
3
1,123
SQLSTATE[22007] Invalid datetime format 1366 Incorrect integer value:a field for column
<p>After login a user, The user enters this skills form, selects the skills.</p> <p><a href="https://i.stack.imgur.com/Rxad6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Rxad6.png" alt="skills" /></a></p> <p>A user can enter multiple skills, and save in database.</p> <p>The field of name</p> <ul> ...
3
2,228
AAPT: error: not well-formed (invalid token). Despite all trials this error continues to pop
<p>I am making an app for a tic tac toe game using android studio . But it's showing this error . I am unable to find any mistake in this xml code. Until now i have not written any code in main activity . This didnt worked in this phase itself. I am a beginner in android development</p> <p>Here's my entire code.</p> <p...
3
2,317
AttributeError at /logout/ 'tuple' object has no attribute 'backend'
<p>I used Python3 in windows 10 to write a django2 web app. I tried to configure the LDAP login, but failed. When I test using postman, it could get the reply successfully. That is, I send a request to <a href="https://example.com/staff" rel="nofollow noreferrer">https://example.com/staff</a>, with some authentication ...
3
1,935
ValueError at /issue/1/comment Cannot assign "<SimpleLazyObject: <User: miko>>"
<p>So I'm trying to create a simple Comment feature for a blog app. In the Class-based views, if you are using a Foreign Key in your model, I know that you have to override the def form_valid: in order for the Comment to be posted by the current logged-in User.</p> <p>I did this for the Blog model in my app, and it wor...
3
1,538
Can't get bootstrap modal show on submit
<p>I tried using the following code to show a modal pop up after the user enter data and click on a button on existing modal pop up. Can anyone point out what I did wrong.</p> <p><div class="snippet" data-lang="js" data-hide="false"> <div class="snippet-code"> <pre class="snippet-code-html lang-html prettyprint-overr...
3
2,803
How can i pass the selected dropdown list values from .jsp to servlet using ajax
<p>I am using dropdown list in my program and I am selecting dropdown list values using ajax. But the problem is I am unable to pass the selected dropdown values to servlet and servlet must use those values. </p> <pre><code> protected void doGet(HttpServletRequest request, HttpServletResponse response) throws Servlet...
3
4,215
TSQL XML - Node attributes as columns or rows in same query
<p>I'm working with an XML file with a node similar to this:</p> <pre><code>&lt;Process&gt; &lt;Step No=&quot;1&quot; Types=&quot;D&quot; Temp=&quot;25&quot; Secs=&quot;6&quot; Macro=&quot;2&quot;&gt;Enable Mixers&lt;/Step&gt; &lt;Step No=&quot;11&quot; Types=&quot;D1&quot; Temp=&quot;11&quot; Secs=&quot;61...
3
1,188
Improving the performance of an autoencoder network
<p>For a couple of days, I am working to improve the performance of my autoencoder network, from changing the network architecture to manually tuning some parameters and lately using <a href="https://optuna.readthedocs.io/en/stable/" rel="nofollow noreferrer">optuna</a> to optimize hpyerparameters. All to no significan...
3
1,816
Code efficiency. Effective way of using loops
<p>I am building a framework for a web application and would like to perform certain simple tasks like input retrieval and displaying them. Below is have the code, I feel the code can be improved and isn't efficient. Note:All three methods have the same implementation.</p> <p>The Switch needs to be implemented twice o...
3
1,777
Illegal reference to net rddata in FIFO
<p>The below code is for a FIFO. It is showing an error as illegal reference to net datatype as <code>rddata</code> at line 38 in tb (highlighted by adding a comment &quot;//error line&quot;).</p> <p>Why do I get this error?</p> <pre><code>module fifo(clk,rst,error,empty,full,rddata,wrdata,wr_en,rd_en); parameter WID...
3
1,644
How to convert a nested json to a flat csv in jq
<p>I need to convert this json into a flat csv </p> <pre><code> { "Pagination": null, "Data": [ { "ID": 35058, "Marchio": { "ID": 1, "Codice": "APP", "Descrizione": "Apple", "Immagine": "https://api.attiva.com/Artic...
3
8,354
Script optimization, primarily due to for loops [R]
<p>I have a recording of blood pressure and velocity in the resolution of 1000 Hz. During this recording i have identified periods (e.g. 1, 2, 3). The primary problem is with optimization. I have multiple recordings which are between 10 and 15 minutes in length, which results in ~1.000.000 rows.</p> <pre><code> ...
3
1,251
WorkStealingPool exits unexpectedly
<p>I submitted some Runnables to an ExecutorService. Inside these Runnables, wait() and notify() are called. The code works with newFixedThreadPool as the ExecutorService. With newWorkStealingPool, the process exits unexpectedly without any error message. </p> <pre><code>import java.net.URL; import java.io.BufferedRea...
3
2,617
How can i display the distance of a line drawing randomly?
<p>I'm trying to draw to filled circles, centered at random locations, with a line connecting the circles. The distance between the to centers is displayed on the line and whenever your resize the frame, the circles are redisplayed in new random locations. I'm stuck in how to display the distance? Any help is appreciat...
3
1,409
Python code unexpected behavior when entering my loop
<p>I am having a problem with my attack loop, when it runs it gets to the <code>checkAtk</code> function then restarts the direction loop.</p> <p>I don't have a clue what's wrong with this code (and need to fix it before next Saturday). I welcome any advice or hint you might have.</p> <pre><code>import random import ...
3
1,285
Nx Monorepo - How to Use NestJs Library inside the Main Nest App
<p>I am working in an Nx monorepo workspace. The workspace structure is something like below:</p> <p><a href="https://i.stack.imgur.com/zenPw.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zenPw.png" alt="enter image description here" /></a></p> <p>The <code>api</code> is a NestJS app, and the <code...
3
1,500
why does this get method returning this message?
<p>I have this function that tabulates the user specific data. Its a get method that sends a query parameter userId:</p> <pre><code>&lt;script&gt; let thisArray = [] let = userId = $('#userId').val(); $.ajax({ method:'GET', url:'/auth/marcacoesGET/:us...
3
1,633
I need to understand classes
<p>I am writing a new booking system seeing as one I have written before is now years old and looking shoddy. I want to write one that is very flexible and portable and I want use classes.</p> <p>I am new to classes and OOP in the php language, I've written one class before and that went well. However I am confusin...
3
1,570
How to generate a log file names with sequence numbers?
<p>I want to dump the logs into a log file. After the max size limit of the file is reached I want to rename the file with a number ( format will be like log.%d).</p> <p>There is a limit to the number of backup log files. after the limit is reached I have to delete the oldest created log file too.</p> <pre><code> void ...
3
1,263
Getting an Error while trying to write data from Google PubSub to GCS using Apache Beam in Dataflow
<p>I have written the below code to write the streaming data from pub sub and write it into google cloud storage.</p> <pre><code>def run(): argv = [ '--project={0}'.format(PROJECT), '--job_name=mypubsubsample40', # '--save_main_session', '--staging_location=gs://abc/staging/', '--temp_location=gs://abc/sta...
3
2,779
Asp.net Core Web Api returning a 401 when user is logged in
<p>I have an Angular front end application connected to an Asp.Net Core Web API backend running on two different ports (front 4200, back 5001) running locally everything runs just fine, but when it is published to the site I am receiving a 401 error when trying to access anything with an Authorize attribute on it. I am...
3
1,999
Print Content Of Bootstrap Modal Window
<p>I have a table in laravel with different data in the lines and a button that opens a mondal with the information, but when I open the modal and click on the button inside the modal to print it does not work.</p> <pre><code> &lt;div class=&quot;modal-footer&quot;&gt; ...
3
1,116
I can't use an API on Javascript, Might be related to node.js and such
<ol> <li><strong>Okay so I'm new to Javascript, please keep that in mind, and I'm working from a directory in my home computer, like, the web is not hosted in a server or anything, I've never done that</strong></li> </ol> <p>I've been trying to work with a Google Translate API (<a href="https://github.com/matheuss/goog...
3
1,105
Php show users data from mysql with dropdown list
<p><a href="https://i.stack.imgur.com/iPgis.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/iPgis.png" alt="enter image description here"></a>i want to display users data in a table with the dropdown list , the first option shows all the users but when i click a name it still shows all users, i think...
3
2,690
Error when parsing JSON Data from my URL
<p>I'm developing an android application based on remote database , I found solutions on how to put data in the database but I'm having much problems on getting it back. When I open the activity that gets the data the app crash. I couldn't localise where the error is in my code!! so here is my code and I hope you can h...
3
4,593
Django: can't trigger AJAX call and send values back to my form
<p>I need to run an AJAX call to perform a quick calculation in my django view and return the result in my html page, inside a tag.</p> <p>I'm very new to Javascript so I don't understand why my AJAX call hasn't been triggered. This is my html and JS code:</p> <pre><code>&lt;input type="text" name="SHm2" maxlength="...
3
1,029
jQuery - Building a tree style list
<p>My DOM is as follows</p> <pre><code>&lt;ul&gt; &lt;li id="Browse"&gt; Browse &lt;ul id="browse-one"&gt; &lt;/ul&gt; &lt;/li&gt; &lt;/ul&gt; </code></pre> <p>My jQuery in a in the bottom of the page is:</p> <pre><code>$("#Browse").click(function() { $("#browse-one").html('&lt;...
3
2,068
Convert C# function into Swift 4.2
<p>I found <a href="https://forum.unity.com/threads/2d-tile-bitmasking.513840/" rel="nofollow noreferrer">this thread</a> talking about <a href="https://gamedevelopment.tutsplus.com/tutorials/how-to-use-tile-bitmasking-to-auto-tile-your-level-layouts--cms-25673" rel="nofollow noreferrer">this article</a>. I found some ...
3
1,437
What Javascript, Jquery, and css code do I need to have a side bar exactly like this?
<p>I'm wanting to create the sidebar from this website (<a href="https://www.alexcoven.com/" rel="nofollow noreferrer">https://www.alexcoven.com/</a>) but I'm having trouble figuring it out. Can you guys please help me create the positioning/color and animation of the sidebar. The html code is there, just not the anima...
3
2,939
digester parser error java.lang.NoSuchMethodException: Employee.<init>()
<p>I am trying to parse an xml using digester . </p> <p>My XML </p> <pre><code>&lt;root&gt; &lt;Employee&gt; &lt;Id&gt;1&lt;/Id&gt; &lt;FirstName&gt;Charles&lt;/FirstName&gt; &lt;LastName&gt;Madigen&lt;/LastName&gt; &lt;Location&gt;Louisiana&lt;/Location&gt; &lt;Skill&gt;Accountant&lt;/Skill&gt; &...
3
1,458
c# WSDL without Header but requested
<p>Even if the application is similar to one made recently, rephrase in the correct terms, maybe I can better understand what my problem, since I have so far tried unsuccessfully a solution and the ones I found were not for the My case</p> <p>Abstract: first time I'm dealing with web service, soap, appurtenances, so f...
3
2,217
Getting rid of wash out rows in R dataframe by group
<p>This is what my dataframe looks like:</p> <pre><code>df &lt;- read.table(text=' CustomerName Sales TradeDate John 1000 1/1/2015 John -1000 1/1/2015 John 1000 1/1/2015 John 5000 2/1/2015 Joh...
3
1,464
I am trying to consume a webservice through jquery but it throws this error No 'Access-Control-Allow-Origin'
<p>I am trying to consume a webservice through jquery but it throws this error:</p> <blockquote> <p>No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. The response had HTTP status code 500.</p> </blockquote> <p>I read that it's related ab...
3
1,377
Packaging an object for a model with a dynamic route is undefined — why?
<p>Playing around with with EmberJS, and I'm trying to understand some behaviour with routes right now. </p> <p>I'm building a test app with the intention of hooking into the Rdio API and displaying albums/songs for various artists. </p> <p><a href="http://jsbin.com/puqokupura/1/" rel="nofollow noreferrer">Here's a J...
3
1,333
Bring back sibling values within a parent node
<pre><code>&lt;po-response xmlns="http://test.com/oms/v3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="rest/oms/export/v3/purchase-order.xsd"&gt; &lt;!--Generated on host [spapp403p.prod.ch4.s.com]--&gt; &lt;purchase-order&gt; &lt;customer-order-confirmation-number&gt;335342876&lt;/...
3
2,690
I am getting 403 forbidden using spring boot 3.0M4 and java 17
<pre><code> package org.tnc.application.security.config; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.http.HttpMethod; import org.spring...
3
1,069
Integrating apollo-angular V2 with Angular V8
<p>I am trying to integrate apollo-angular into my Angular project which uses Angular V8 but getting the following errors:</p> <p>The apollo-angular versions im using are the following ones: &quot;@apollo/client&quot;: &quot;^3.4.11&quot;, &quot;apollo-angular&quot;: &quot;^2.6.0&quot;, and &quot;graphql&quot;: &quot;^...
3
2,600
How to prevent spyder from crashing if there is too much data in list?
<p>I am running the below code to get XML objects from an API in <code>Anaconda Spyder</code>. The XML objects appended in a list, keep getting larger. For some reason <code>spyder</code> keeps crashing, from what I believe is the list getting to large. </p> <p>I have to make roughly ~300K api calls for which I need d...
3
1,030
Null reference when trying to post with ViewModel
<p>Currently I have a ViewModel which is comprised of 2 lists of models. Displaying contents using the ViewModel is fine, however when I try to post I get a null reference exception.</p> <pre><code>public class DashboardViewModel { public IList&lt;DashboardModel&gt; dashboard { get; set; } public IList&lt;Wid...
3
1,290
How can I push to a subarray by grouping messages it in JS?
<p>I'm not very sure how I should name this question but I'll try to explain my problem. At the moment I've an array in PHP with some entries.</p> <pre><code>Array ( [0] =&gt; stdClass Object ( [sender_id] =&gt; 0 [message] =&gt; Test [created_at] =&gt; 2020-03-12 16:26:...
3
1,360
Trying to get div to stick at the top while scrolling a page. It is staying at the top but the CSS is getting deformed
<p>I have a type of search box div for my site that I want to stick to the top when the user scrolls down to look at the data. Though when I scroll down, the div stays at the top, but everything gets deformed.</p> <p><strong>EDIT:</strong> I am not using any extra CSS for the divs. It is a Bootstrap container class di...
3
1,108
I need help making buttons appear and disappear on JPanel (if statement not working to check if a condition for an int is met)
<p>Nothing appears to be wrong with this from what I have seen</p> <p>Code for Driver:</p> <pre><code>import javax.swing.JFrame; import java.util.Scanner; import java.util.Random; public class rpsDriver{ public static void main(String[] args){ //jpanel stuff JFrame frame = new JFrame(&quot;Rock Paper Scissors Ga...
3
3,289
How can I fix the error "Error: The pipe 'filter' could not be found! Error: The pipe 'filter' could not be found! "In angular 10?
<p>I have a filter that when searching for a name brings me the data that contains that name, but it only sends me that error in the browser console. it just doesn't show me the page</p> <pre><code></code></pre> <p>html</p> <pre><code>&lt;div class=&quot;content&quot;&gt; &lt;div class=&quot;container&quot;&gt; &lt;div...
3
1,866
Can't Move Group backwards! Corona SDK
<p>i'm new here, i'm trying to do a videogame for android with corona sdk, but i'm stuck with the creation of random particle on the background, here is the code:</p> <pre><code>local menu = composer.newScene() function menu:create( event ) local bg = self.view local particlesGroup = self.view local sceneGroup ...
3
2,049
How to sort the loaded XML data
<p>In my application, I have an <code>XML</code> file that connects to different API and gathers information. Then in a <code>div</code>, it shows the fetched information. I do it successfully, but the issue is, the <code>XML</code> will not load if element one by one. It loads data in parallel, so the <code>div</code...
3
1,379
Android Jsonwriter writes 0 instead of my value into the file
<p>I have a Jsonwriter which is writing into a file. I want to save all of my Book objects which have id, title, author, releasedate, type, description and link. I still get 0 at the releaseDate name, but in the array there is the right value.</p> <pre><code>JsonWriter writer = new JsonWriter(new OutputStreamWriter ...
3
2,154
gestures detector is not working
<p>i am working on application in which i want to implement gestures detector.when user double click then it should display the next image and when he give a single click then it show the description....... my code is as follow ....... </p> <pre><code>public class FirstImage extends ImageView implements OnTouchList...
3
1,894
Problem with displaying a modal using PHP script
<p>I have a problem with the modal system on my website. Now I will provide you some code:</p> <pre><code>MODALS ARE MADE WITH W3.CSS LIB </code></pre> <p><strong>modal.js (with some debug)</strong></p> <pre class="lang-js prettyprint-override"><code>let modal = null; let title = null; let content = null; $(document)....
3
3,478
My CSS columns are not going next to each other
<p>I have 2 css columns on my website: the right one is 25%, and the left one is 75%. However, right now it doesn't show the right column, the left column takes up 100%, and if I try to put something in the left column it puts it on the bottom of the page. I changed one unrelated thing, I don't even remember what, and ...
3
3,104
Why service-worker does not cache js file
<p>SW caches an image file, but not JS (size 0 bytes)</p> <pre> /*serviceWorker*/ if ('serviceWorker' in navigator) { navigator.serviceWorker .register('service-worker.js', { scope: '/' }) .then(function(registration) { console.log("Service Worker Registered"); ...
3
1,245
Failed to integrate redis server with express node js app
<p>I am new to Node.js and I have been trying to create a small app integrated with KUE library for task queuing.</p> <p>When I trying to run the app i.e. <code>node app.js</code> I get the following error:</p> <pre><code>{ ReplyError: ERR wrong number of arguments for 'set' command at parseError (.......\node_mo...
3
1,092
How to add a grid to my program without that all of the rest of the program will be deleted?
<p>This is my code: </p> <pre><code>import wx import wx.grid as gridlib from random import randint OPTIONS = [1, 2, 3, 4, 5, 6, 7, 8, 9, "DEL", 0, "SEND"] # these are the events' IDs sent to a function when you click a button. # the OPTIONS_ID is in the same order of OPTIONS. OPTIONS_ID = [-31990,-31989,-31988,-3...
3
2,501
JAXB, How to unmarshal XML element as list instead of object?
<p>My application integrates with another application that produces XML , they gave me the XSD and sample XML</p> <p>I've a question regarding this piece:</p> <p>XSD :</p> <pre><code>&lt;element name="IubLink"&gt; &lt;complexType&gt; &lt;complexContent&gt; &lt;extension base="xn:NrmClassXmlTy...
3
1,807
Trying to get multiple messages from an Azure Storage Queue
<p>I have a node.js Function App which I'm trying to use to retrieve a specific message from a storage queue in order to delete it. It doesnt seem like there is a method to get a specific message by ID, so I'm trying to read all the messages, or at least 32 of them, then find the message to delete by ID.</p> <p>My prob...
3
1,239
Failed assertion: 'owner!._debugCurrentBuildTarget == this': is not true
<p>So i am building an to do list app using slidable as Task-Element. However If i want to add a nth task to my database (Sqflite) this error shows up, :</p> <pre><code> The relevant error-causing widget was: MaterialApp MaterialApp:file:///C:/Users/Thana/StudioProjects/taskStack/lib/main.dart:15:12 When the excepti...
3
1,115
How to get out of this token authenticator Hilt dependency cycle?
<p>I have a function that returns an API, which needs an OkHttpClient instance</p> <pre><code>@Module @InstallIn(ApplicationComponent::class) object AuthNetworkModule { @Provides fun provideAuthRetrofitService (@AuthQualifier okHttpClient: OkHttpClient): IQuipsAuth{ return Retrofit.Builder() ...
3
1,157
How do I write an RSpec test that confirms Password Reset Token has been Saved to the DB?
<p>I'm writing a test for my Rails 5 API to confirm a password_reset_token is generated whenever a user requests a password reset. </p> <p>I have a short password_reset_controller that handles the initial request: </p> <pre><code>class PasswordResetController &lt; ApplicationController def new @user = User.find...
3
1,137
Python individual rows for each month's rent in term
<p>I'm stuck on one piece of Python code.</p> <p>From an XML file, we're parsing data successfully in the following code, excluding the while loops and associated variables. We need to load a table into SQL with the entire rent schedule, by month, for the life of the lease. Rent is always billed on the first of the ...
3
1,313
Not able to publish project documentation to Apache using WebDAV protocol after using mvn site:deploy command
<p>I am trying to deploy a project related information using <code>mvn site:deploy</code> command but I am getting following error. </p> <p>Can somebody please guide on this as what is the missing piece here?</p> <p><strong>Error Log:</strong></p> <pre><code>http://gsi-547576/sites/ - Session: Opened [INFO] Pushing ...
3
2,254
CKQueryNotification.recordID: unrecognized selector sent to instance
<p>I'm trying to set up silent push notifications to propagate local notifications across devices using CloudKit and I can't wrap my head around why my app is crashing every time I receive a remote notification. </p> <p>Everything works just fine until I try to process the notification received. The crash occurs when ...
3
1,164
Trasition doesn't work with addClass and RemoveClass
<p>I would like when scrolling container, my menu change her heigth, width and hide her title, I have got it but don't work the transition that I added.</p> <p>html:</p> <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false"> <div class="snippet-code"> <pre class="snippet-cod...
3
1,464
User Registration Table in PHPMYADMIN not storing any data added
<p>I am new to phpmyadmin and sql! I have created a database connection through dreamweaver CC using SecureWamp. It is all connected to my table etc but no matter how many times I enter information into my 'User Registeration' form, none of the information is showing in phpmyadmin. This is the code I have: Local Host C...
3
2,275
Apexcharts Heatmap: display exact x value on hover for each series data
<p>I'm trying to create a heatmap using apexcharts that shows frequency of activites each week in a year (Check the github contributions heatmap). My goal is to display a tooltip that shows the <strong>specific date</strong>, <strong>week day</strong>, and <strong>frequency value</strong> whenever the user hovers on a ...
3
1,309
XPTY0004 Item expected, sequence found, How to find whether a value is present in a sequence or not using Xquery
<blockquote> <p>Hi.. I would like to find whether a value is present in a sequence or not ,for example If I have an XML which looks like below</p> </blockquote> <pre><code>&lt;module&gt; &lt;content&gt; &lt;customer SC=&quot;25&quot; item=&quot;200&quot;&gt; &lt;Number id=&quot;250&quot;&gt; &lt;Character Value=&quot;P...
3
1,554
Token matching, but it shouldn't
<p>I am trying to parse Windows header files to extract function prototypes. Microsoft being Microsoft means that the function prototypes are not in a regular, easily parseable format. Routine arguments usually, but not always, are annotated with Microsoft's Structured Annotation Language, which starts with an identifi...
3
2,508
Different versions of android, different display
<p>I have created a mobile application using ionic framework. It consist of many html pages. For android version <strong>KitKat</strong>, the pages are displaying correctly. For android version <strong>Jellybean</strong>, the pages are displaying differently. Please see the html &amp;css code?</p> <p><strong>Login.htm...
3
1,907
'Error inflating class Button' despite working before
<p>After implementing some buttons within my layout the following error appears within the logcat during app deployment:</p> <blockquote> <p>android.view.InflateException: Binary XML file line #37: Error inflating class Button</p> </blockquote> <p>I really don't understand why this is happening when it was working ...
3
5,059
Why this class starts the intent twice?
<p>I have my SplashScreen activity with AsyncTask to check for files if exist. If they exist starts MainActivity class else starts the Downloader class. </p> <p>The problem is when splashscreen is done, it runs the MainActivity intent twice or the Downloader intent twice. I am using android version GINGERBREAD</p> <p...
3
1,138
Error opening file because of an unknown format
<p>I read some Audio file, labeled them, and together with their path, save the path and emotion of each Audioo file in a csv file. Now I want to read their path from the file and open them but I get this Error:</p> <pre><code>--------------------------------------------------------------------------- RuntimeError ...
3
2,416
How should I migrate this data into these Sql Server tables?
<p>I wish to migrate some data from a single table into these new THREE tables.</p> <p>Here's my destination schema:</p> <p><img src="https://i.stack.imgur.com/6fPmI.png" alt="alt text" /></p> <p>Notice that I need to insert into the first <code>Location</code> table .. grab the <code>SCOPE_IDENTITY()</code> .. then i...
3
1,039
LoadError: incompatible library version, when deploying with capistrano to Digital Ocean
<p>When I run cap staging deploy, I get the error </p> <pre><code>LoadError: incompatible library version - /var/www/dbname_staging/shared/bundle/ruby/2.6.0/gems/msgpack-1.2.10/lib/msgpack/ms… </code></pre> <p>Assets won't precompile when deploying with capistrano to production on Amazon EC2. But I didn't find any so...
3
6,426
Storybook Angular cannot resolve parameters on base class
<p>I am in the process of adding storybook into an existing app. Apart from a few painful issue which are now behind me, it's been mostly a success, however I have encountered a new issue. I have multiple components which extend from an abstract base class which are complaining they cannot resolve parameters for. EG: <...
3
1,038
Create cookie for div
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false"> <div class="snippet-code"> <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://www.gstatic.com/firebasejs/4.11.0/firebase.js"&gt;&lt;/script&gt; &lt;script&gt; // Initialize Firebas...
3
3,667
Error to define a long column in oracle
<p>I have a problem with a simple script in sql:</p> <pre><code>SQL&gt; alter table myTable modify myColumn default 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX...
3
1,079
The program compiles but it gives an error when ran
<p>While trying to run this code I run into an error but not while compiling it. At the end of each directional method I call the next method in the order that is supposed to go in. What I am trying to do is make a program that will read a maze from a file and solve it. While solving it I want the program to place a P ...
3
2,116
Adding a database result to an array and fill another respective array to the same database table
<p>I have written a program to insert an array in all the rows of a column in a database table with respect to already filled column in the same database same table. </p> <p>But it doesn't seems to work properly. Please tell me where I am going wrong! </p> <pre><code>$query = $sql = "SELECT A FROM `table`"; $result1 ...
3
1,508
Field is required when it is not .net Core entityframeworkcore
<p>I generated context and model by running nuget command line</p> <pre><code>Scaffold-DbContext "Server=(LocalDb)\MSSQLLocalDB;Initial Catalog=DummyDB; Integrated Security=True;Connect Timeout=30;" Microsoft.EntityFrameworkCore.SqlServer -outputDir Context -Context DummyContext </code></pre> <p>When I tried to pass...
3
1,149
Undefined symbols for architecture arm64, it seems just randomly happened to some third party framework using cocoapods
<h2>What happened</h2> <ol> <li>I used <code>Cocoapods</code> to manage some third-party frameworks</li> <li>I used some private spec repos</li> <li>More than one private repos have dependency on same third-party pods</li> <li>After a modification of dependency structure,I build my workspace, it shows these errors:</li...
3
2,815
What is the best approach to solve a N to N relationship algorithm problem?
<p>I'm trying to write an algorithm to organize the schedule of N rooms to N professionals. I have a List of Room objects and another List of professionals. The idea is to be able to assign a professional to a specific room for the day. The twist here is that the professional can be of kind &quot;specialty&quot; (repre...
3
1,746
How to use subcriteria in populate (for example : .populate('something',{select:[]})) in sails js
<p><code>.populate('something',{select:[]})) in sails js .</code> for me its an ambiguous usage. Is there any alternate solution for the problem </p> <p>I used select inside populate ... but it shows sub-criteria doesn't work in this version of sails </p> <pre><code>Banktransaction.find(newData).populate('project_id'...
3
1,090