title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
Javafx FXML Media Player play same Video in two windows simultaneously
<p>im have a simple Media Player created in Java with Javafx FXML.</p> <p>Now what i want to achieve, is to play the video also in a second window, sadly ive got no clue how this is done. I searched other posts about the same question but found nothing what would help me.</p> <p>Here's the code</p> <p>simplemediaPla...
3
4,361
Android setContentView not being applied
<p>Hi I'm this is a reask of a previous question just because i wasn't clear before. i have a json feed that consists which i found the length of the array in it. as it should it produces one. but what i'm trying to do is if a second item were to be added that feed another layout would need to be used.</p> <p>so i cu...
3
1,593
Java GUI Repeatable Process
<p>I recently took up Java and I decided to construct a mini rock paper scissors game. Although, I think it turned out working but badly designed it still has a small problem. I cannot seem to figure out how to make the whole process repeatable because I have to restart the program so that the computer can choose once ...
3
2,250
What happens when you click a button using WebRat under cucumber
<p>I am trying to login to a Java web application. </p> <p>The login page has the following html : </p> <pre><code> &lt;html&gt; &lt;head&gt;&lt;title&gt;Login Page&lt;/title&gt;&lt;/head&gt; &lt;body onload='document.f.j_username.focus();'&gt; &lt;h3&gt;Login with Username and Password&lt;/h3&gt; ...
3
2,118
Storing data from one table to another
<p>I have vehicle master table in mysql called asset. Driver has to enter 3 due dates namely insurance due date, fitness certificate due date and road tax due date in 3 different columns.</p> <p>There is one more table called vehiclenotification table which has notification type column for insurance, fitness and roadt...
3
2,089
For Loop in Protractor is not working properly
<p>I am working on Protractor for testing the Angular JS application. I have written a code to read the data from excel sheet.My scenario is like I have a end to end flow that should execute.The code will take the URL,UserName and Password from the excel sheet and will execute the entire flow. Than again it will iterat...
3
1,249
Printing multiple lines in a window using PyQT5 and Python
<p>I am trying to code a very simple window application. I want it to print some "output" in a part of a window (or in a new one - it doesn't matter).</p> <p>I will try to better explain my problem using the code below.</p> <pre><code>import sys from PyQt5 import QtCore, QtWidgets from PyQt5.QtWidgets import * from ...
3
1,071
run_until_complete fails even after loop has been stopped
<p>Im trying to write a SIGTERM-handler that will have my <strong>run_forever()</strong>-loop</p> <ul> <li>Stop accepting new tasks.</li> <li>Complete running tasks.</li> <li>Shutdown.</li> </ul> <p>Here is a learning-demo I wrote:</p> <pre class="lang-py prettyprint-override"><code>import asyncio import signal impo...
3
2,298
WPF: Execute some code asynchronously in .NET 3.5
<p>I have a MVVM WPF app. I have a window, let's say "LvWindow", with a listview that is loaded from data comming from a database. From main window "MainWindow", I have a menu, which has some options. When I select the option to access "LvWindow", it is open. Then from ViewModel, in the constructor I have a call to a d...
3
1,293
ArrayList Method Returns a null ArrayList, main program cannot access
<p>I'm trying to create a basic function that calls on a method that creates the 2D ArrayList that will be used further in the main program to do things like calculate the row and column sums as well as print out the triangle. However, after it runs the ArrayList returns null. What's going on?</p> <p>Thanks, </p> <pr...
3
1,437
RecyclerView view doesn't change using background_selector
<p>I'm Trying to toggle item background color upon item selection.</p> <p>I can see it's logic is working yet the background wouldn't change. The log prints show the selctions indeed work, yet the background not.</p> <p>From background_selector:</p> <pre><code>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;...
3
1,613
Parse XML with Child Nodes
<p>I have an XML file which returns a list of products with colors and inventory for each color. What is the best method to loop through this data only returning inventory by color for a specific product i.e. PL-0223?</p> <p>Here is the data.</p> <pre><code>&lt;Part fpartno="0019"&gt; &lt;Color colorname="Nickel"...
3
1,076
Setting rendered image into ImageView instead of opeing a new Intent in Android with aChartEngine library
<p>I'm trying to set the rendered image into my ImageView instead of opening a new Intent but getting errors. </p> <pre><code>iv.setImageDrawable(ChartFactory.getPieChartView(getBaseContext(), distributionSeries, defaultRenderer)); </code></pre> <p>here is my code for main class,</p> <pre><code>public class PieChart...
3
1,055
Building my first Javascript Application (jQuery), struggling on something
<p>I'd really appreciate recommendations on the most efficient way to approach this.</p> <p>I'm building a simple javascript application which displays a list of records and allows the user to edit a record by clicking an "Edit" link in the records row. The user also can click the "Add" link to pop open a dialog allow...
3
1,497
emptying text field after user inserts data for next input
<p>I am using jquery that shows popup for input box. when the user inputs data and submits i redirected action to the same insert action so that the text field can be refreshed.at first pop up for input is shown but when i submit the popup shown previous remained as it is and new pop up for the input box is shown in w...
3
1,357
How to loop over and track all form fields
<p>I would like to keep track of all form fields so that I can do different tasks e.g. validation, animation, etc. Currently I have the code written out in long form which repeats itself quite a bit. How can I get each <code>text</code> or <code>textarea</code> or <code>email</code> input from an HTML form and track it...
3
1,899
PHP json_decode variables not being set
<p>UPDATE:</p> <p>Ill be honest, I gave up and did it in sails.js in the end, I will leave this question up in case anyone can see where I went wrong.</p> <hr> <p>wondering if anyone can help me out with a bit of a strange one I can't seem to solve.</p> <p>I have an oAuth script that returns an output of a json arr...
3
1,405
having trouble replacing default zeros in 2d array with white spaces
<p>My goal to to make three different 2D arrays, and for the last two replace all zeroes in the array values for blank spaces instead. I've tried using printf("%s","[]") but instead of replacing the zeros they just add the brackets above the array. i believe it has something to do with the placement of my else stateme...
3
2,163
Using UNION clause in OPENQUERY to query Oracle Linked Server with VBA
<p>I am considerably new to SQL and VBA. I am trying to execute the following Oracle SQL query using OPENQUERY in VBA to query a Linked Server:</p> <pre><code>with untagged_affiliates as ( select ife.entityid, 'Untagged affiliate' as TYPE_CHANGE, to_number( case when IFE.OLDVALUE is not null ...
3
2,217
How to bind a dynamic child list using Thymeleaf and JQuery?
<p>I am a complete newbie and I really hope you can help me!</p> <p>I have two entities: Recipe and Product. The recipe object contains a list of products, the size of which is &quot;controlled&quot; by the user - it changes based on how many products the user would like to include.</p> <p>This is my <strong>Recipe Ent...
3
1,374
Cannot create listitem via rest api in sharepoint2013 with contribute rights
<p>I have an issue with our Travel Tool based on SharePoint 2013.</p> <p>This tool consists of different Content Types - all in their specific lists (travel requests, train rides, flights, etc.). There are two main groups which are using this tool: Employees (contribute) and admin staff (full control). On the homepage...
3
1,086
Reoder TRs in responsive format using jQuery
<p>Looking for some assistance on a table I have. Markup is below. Basically at a breakpoint I want to move TR 2 to become TR 4 and TR 5 to become TR 3. Then above the breakpoint I want to reverse the changes, I have some code which is kind of working, but it keeps spawning new TRs as i need the code to work on window....
3
1,043
how to find the match value and display value automatically on dropdown
<p>Just want to know how to find the match value on the dropdown list and display the value as current selected for update. </p> <p>this is my table query and displayed on page with update link beside each row. All update link is working and the value displayed on hidden textbox. My problem is just on one column $tran...
3
2,350
How can we read memory mapped file data of 32 bit 3rd party application from a windows service application?
<p>I have a 32 bit third party application's dll. It is of type library project and creates a memory Mapped File named <strong>MappedObject</strong>. This is the section of code indicating generation of mmf file:-</p> <pre><code>#include "stdafx.h" #include "dllmain.h" #include &lt;stdio.h&gt; #include &lt;tchar.h&gt;...
3
1,188
Anchoring Rendered 3d Model to CharUcoBoard with OpenCV to OpenGL Pose Estimation
<p>I am having difficulty spotting the issue in my code with regards to an OpenCV to OpenGL pseudo augmented reality program. I say &quot;pseudo&quot; because the constraint is taking images and mat objects from openCV and converting them to OpenGL.</p> <p>I have working models rendered, have used the cv2.rodrigues met...
3
2,126
Hover animation does not work in QSS in PyQT5
<p>I am trying to create my first UI in PyQT5. However, I am unable to add a hover-animation to my button and I can't figure out why it does not work.</p> <p>I am trying it with this stylesheet, instead off QPushButton#authenticate_button:hover I also tried #authenticate_button and QPushButton, nothing seems to work :<...
3
3,789
regex expression does not match as expected in Python
<p>I have the following text:</p> <pre><code>'1. Θεόδωρος Φέσσας του ∆ηµητρίου και της Ελένης, Μηχανολόγος - Ηλεκτρολόγος, που γεννήθηκε στη Θεσσαλονίκη, το έτος 1951, κάτοικος Καλλιθέας Αττικής, οδός Αργυρουπόλεως 2Α, κάτοχος του υπ’ αρ. ∆.Α.Τ. ΑΕ 106909/0504- 2008, Τ/Α Βουλιαγµένης Αττικής, µε ΑΦΜ 015299388, ∆.Ο.Υ. ...
3
1,321
Debugging basics
<p>I'm new in programming, and I'm trying to code my first app in swift. I've got my App crashing at runtime, but I'm not able to understand a word in Xcode debug navigator. I can't post a screenshot as this is my first post at StackOverFlow.</p> <p>Could you help me to interpret XCode6 (Swift) crash console. How can ...
3
1,897
Unable to see my textbox data in Datagrid by clicking button using MVVM pattern?
<p><img src="https://i.stack.imgur.com/wyvpR.png" alt="enter image description here"></p> <p>Hi guys i have a problem since last week and i am unable to sort out the reason,the problem is i want my textboxes data to be display in a datagrid ,i am using WPF C# and pattern is MVVM.</p> <p>My code in XAML is:</p> <pre>...
3
2,159
Site Header Responsiveness
<p>TLDR: The site gains a horizontal scroll bar around width 460px and I'm stumped.</p> <p>New to learning web development, I've learned a bit about working with grid and flexbox, but I still struggle at times with making sections of a site responsive. In this current personal project, I'm aiming to make a header secti...
3
5,058
How can I multiply an Armadillo matrix with a NumericVector obtained from qnorm()?
<p>When I try to multiply an arma::mat and a NumericVector in Rcpp using operator*, I get the following error:</p> <pre><code>no match for operator* </code></pre> <p>Here is an example of what I'm trying to multiply:</p> <pre><code>NumericVector exampleNumericVector(L-1); arma::mat exampleMatrix(L-1,L-1); exampleMatrix...
3
1,346
Why does enabling timer to auto start disable my stop and reset buttons?
<p>Thanks for any help here, not sure what's going on - but when I enable the <code>timer();</code> line in order to automatically start the timer when the page is loaded, it disables the stop and reset buttons. I tried to only include relevant code here. Can anyone shed some light on why this is happening? Thank you i...
3
2,182
On click event google map add marker Extjs
<p>Hello I click event Implemented but nothing hapens.I am using MVC Extjs I know how to implement in javascript for example<a href="http://jsfiddle.net/fatihacet/ckegk/" rel="nofollow noreferrer">jsfiddle</a> simple click event but in extjs where I should put the code I have gmappanel in window how to handle this in ...
3
5,102
Stored procedure giving error while adding two more columns
<p>I have an SP, which was working fine until I added two more columns. Now after adding two more columns it started giving error as</p> <blockquote> <p>The select list for the INSERT statement contains fewer items than the insert list. The number of SELECT values must match the number of INSERT columns.</p> </block...
3
3,235
`serie: true` cannot ensure loading order of modules
<p>I want to load <code>CodeMirror</code> by <code>ocLazyLoad</code>. Since <code>xml.min.js</code>, <code>htmlmixed.min.js</code>, <code>css.min.js</code>, etc. all need <code>codemirror.min.js</code> to be loaded before them. I try to use <code>serie: true</code> to make sure the loading order:</p> <pre><code>$ocLaz...
3
1,576
Merge Sorted Arrays: LeetCode Submission has different output than LeetCode Playground and Visual Studio [C#]
<p>Trying to attempt to solve 88. Merge Sorted Array with C# using a for and a while loop. Leetcode instructs to save the correct output in [nums1] array instead of a return output. These are the assumptions and inputs for the merge sorted array.</p> <ol> <li><p>Prompt: <a href="https://i.stack.imgur.com/wpEW4.png" rel...
3
1,143
where like over varchar(500)
<p>I have a query which slows down immensely when i add an addition where part</p> <p>which essentially is just a like lookup on a varchar(500) field</p> <p>where...</p> <p>and (xxxxx.yyyy like '% blahblah %')</p> <p>I've been racking my head but pretty much the query slows down terribly when I add this in.</p> <p...
3
1,084
Observable DataBinding ObservableInt vs. LiveData with different results On Confguration change
<p>I am testing the behavior of <code>DataBinding</code> observable when it comes to use a <code>LiveData</code> vs. <code>ObservableInt</code>.</p> <p>I have simple layout with a button that triggers a counter for both <code>LiveData</code> &amp; <code>ObservableInt</code> variables that I store in the <code>ViewMode...
3
2,180
How to make Column child align at left while the other child align at right?
<p>Hey I tried to build a chat app like this, and I have a hard time to align the time for each message. I want the chat bubble follow the size of the message, and the time is always on the right side of the message bubble.</p> <p><a href="https://i.stack.imgur.com/zobuA.png" rel="nofollow noreferrer"><img src="https:/...
3
1,296
How to print nodes to thermal printer - JavaFX
<p>I want to print nodes with their content (<code>ImageView</code>, <code>Label</code>, <code>VBox</code> etc) to a thermal printer. I already have the nodes ready and set to fit the size of an 80mm paper.</p> <p>The problem is when I try to create a custom paper size to fit the 80mm paper size of my thermal printer...
3
1,764
OpenTok failing to add Subscriber video after establishing session on Cordova Android
<p><strong>Issue</strong> </p> <p>Subscriber video for device not being added to dom element after establishing OpenTok session.</p> <p><strong>Expected behavior</strong></p> <p>After the OpenTok <code>session</code> receives the <code>streamCreated</code> event:</p> <ul> <li>subscribing the session to the <code>e...
3
1,707
Finding equal frequency from discrete data
<p>i have to find equal width from time series data.</p> <p>So far,i could do it by manually selecting every single column,and then applying the condition. But i need a faster way to do it.</p> <p>The time-series data:</p> <pre><code>Time ulaR trxA 0 0.6457325 0.4040438 50 0.4594477 0.4172161 1...
3
1,135
How to make my carousel fill only 60% of screen size so the rest can be used by panels directly below it
<p>How could I make the following carousel fill only 60% of screen size (without scrolling) so the remaining 40% can be used by panels directly below it. Images would have to shrink along with carousel depending on desktop screen-size to fill only 60%.</p> <p>Please note: I have looked at the post <a href="https://sta...
3
4,618
How to list oneToMany using ZF2 and Doctrine
<p>I am trying to create listAction() to list all data from an Entity. I have used the example listed in <a href="https://stackoverflow.com/questions/22648186/update-two-tables-from-one-form-with-zf2-and-doctrine/">Update two tables from one form with ZF2 and Doctrine</a> and <a href="https://github.com/doctrine/Doctri...
3
2,395
Parse, saveAll failing after two httpRequests (Cloud Code job)
<p>I am running a job that does the following</p> <ul> <li>httpRequest</li> <li><ul> <li>processing</li> </ul></li> <li><ul> <li><ul> <li>httpRequest to different server using some of the processed data</li> </ul></li> </ul></li> <li><ul> <li><ul> <li><ul> <li>more processing, extending a Parse.Object model and then</...
3
1,663
How to compare id in array Twig
<p>In my project I have to display a list of <code>DOSSIERS</code> that have the same department as the logged user — who can have 1 to N departments. A <code>DOSSIER</code> has only one department.</p> <p>So I would like to make a condition that would display that <code>DOSSIERS</code> that have a <code>department.id<...
3
3,165
Why this bayesian structural time series analysis is showing only 10 years of predicted data?
<p>I used this data below (not original data) for bayesian structural time series analysis</p> <pre><code>df1=structure(list(Year = c(1985, 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 201...
3
1,649
Spark query to aggregate and update values in a table for a parent child relationship
<p>I have the following tables (Each table has other columns as well, but not needed here)</p> <p><strong>Item table</strong></p> <pre><code> user_id, party_id, parent_user_id 1, X, null 2, X, 1 3, X, 1 4, Z, null 5, ...
3
1,052
Why won't Ghostscript recognize my modified 'cidfmap' file?
<p>I'm attempting to use Ghostscript 9.27 on Windows 10 Pro to compress a PDF with CID fonts, using a modified 'cidfmap' file ($GS_HOME/Resource/Init/cidfmap). However, Ghostscript doesn't seem to recognize my changes to 'cidfmap', and instead wants to load the DroidSansFallback TrueType font to emulate the missing CID...
3
1,108
JOOQ, Unknown column 'ideas_service.parent_section.id' in 'on clause' when joining multiple tables
<p>So I have five tables I am trying to get back in one query</p> <pre><code>parent_section(id, gate_id) Assessment_Question(id,parent_section_id) Assessment_question_multi_choice_option(id, question_id) Assessment_answer_Group(id, entity_id) Assessment_Answer(id,assessment_question_id, assessment_answer_Group...
3
1,337
No Session found for current thread at org.springframework.orm.hibernate4.SpringSessionContext.currentSession(SpringSessionContext.java:106)
<p>I have configured the <code>datasource</code> and configured the <code>sessionfactory</code> object, but I am not getting the <em>data-base</em> session from factory object.</p> <p><strong><em>Exception</em></strong>: </p> <pre><code>org.springframework.orm.hibernate4.SpringSessionContext.currentSession (SpringSes...
3
3,593
Cloud Scheduler Not Working With Cloud Run Jobs I think it is my URL
<p>Hi I have a Python script running fine in the new Cloud Run Jobs service that GCP have released. What I am having problems with is Cloud Scheduler. - This is cloud run jobs not just cloud run.</p> <p>I think that perhaps the URL is wrong but I am not sure 100% here are the logs. It seems to be saying that it can't f...
3
1,242
Map function returns the same result on all buttons
<p>I am tyring to map an object that looks like this:</p> <pre><code>['note_title_test', 'note_title_test2', 'note_title_test32', 'note_title_test232', 'test title', 'testing1'] </code></pre> <p>Here is my map function:</p> <pre><code> {results.map((note, idx) =&gt; { console.log(results);...
3
1,804
Building ML classifier with imbalanced data
<p>I have a dataset with 1400 obs and 19 columns. The Target variable has values 1 (value that I am most interested in) and 0. The distribution of classes shows imbalance (70:30).</p> <p>Using the code below I am getting weird values (all 1s). I am not figuring out if this is due to a problem of overfitting/imbalance d...
3
1,299
Why does my fixed navbar dosen't work with images?
<p>I wanted to try a fixed navbar, but the images overlap the navbar. if you scroll trough my page the images go over the navbar and the other elements beneath. Is there a way to fix it? i suspect it's about the relative position of my figure but I don't know how to change it.<br> Also all suggestions are welcome. I'm ...
3
3,127
deleting a mongodb document which is associated with ng-repeat gives "Duplicates in a repeater are not allowed"
<p>I am retrieving an entire "collection" from my mongodb database as array of json objects, "tests".</p> <p>The "tests" is in following format</p> <pre><code>[{...},{...},{...}] </code></pre> <p>I am using this array to populate a table in html using ng-repeat in angularjs.</p> <pre><code> &lt;table class="ta...
3
1,934
Unexpected behaviour using Block-based callbacks with CBCentralManager / CBCentralManagerDelegate and [NSThread sleepForTimeInterval]
<p>I am trying to write some code to scan for bluetooth devices for a while, and then return the array of discovered peripherals through a block-based callback. Blocking code should not be an issue as the code will be called asynchronously.</p> <p>After reading up on the API documentation my initial plan of attack was...
3
2,593
how to select a row a matching a text with protractorjs
<p>we are using protractorjs and node for our test automation. as we have two web application one with customer facing which is ReactJS application which has very reactive elements on those we are using this framework. In the agent facing application we have a page which has normal html table. i was trying to match the...
3
1,838
Changing a Dashboard from bootstrap 3 to bootstrap 4, how to fit the partialViews inside
<p>I changed all the elements of my dashboard, for an example of the boostrap site itself, but after I made the change, all my partial views opening below the components of the admin screen</p> <p>ScreenShot:</p> <p><a href="https://i.stack.imgur.com/im1J7.png" rel="nofollow noreferrer"><img src="https://i.stack.imgu...
3
1,389
Returning values from database to WebMethod
<p>I need to enter some value in the textbox end save it to the database. But if there is a duplicate value then the value must not be saved.</p> <p>Basically, string lvl is successfully passed to the WebMethod from front-end via ajax.</p> <p>Procedure getDuplicate is a simple select that checks if there is a value o...
3
1,177
Could someone help me Understand ex23 in Zed Shaw's Learn Python 3 the Hard way
<p>I'm trying to decipher Zed's ex23 and his explanation is somewhat helpful but I'm getting lost. This script deals with him trying to teach you how to decode and encode letters in different languages it seems. A few of these topics seem premature/ he didn't go over it yet, and he mentions that this is on the harder e...
3
1,027
Video produced by ReplayKit is constantly skipping frames in Xamarin
<p>I have a very basic video recording project that was working perfectly in Swift, but the same code ported into a blank project in Xamarin is producing a video that is constantly skipping frames every few seconds. The code starts in <code>ViewDidLoad</code> and is stopped via a <code>UIButton</code> Here is the recor...
3
1,425
Web page not shifting far enough for mmenu
<p>I have setup mmenu to clone my current menu and put a toggle button that only appears when the screen is less then a specific width. This all works and mmenu worked without an issue. I have sense updated my code to add in new items for the site and now the mmenu doesn't work completely.</p> <p>The menu still comes ...
3
7,900
Dropdown menu doesn't become visible on .drop:hover
<p>I'm creating a menu, where if I hover over the li class="drop", then the visibility of my #competences-dropdown should become visible, but it doesn't wanna work for some reason. Can someone please help by telling what didn't I noticed?</p> <p><div class="snippet" data-lang="js" data-hide="false" data-console="true"...
3
1,238
Dynamically resize Simple Modal Depending on what is clicked
<p>I am fairly new to jQuery/JavaScript so I am having a few problems, hopefully you can point me on the right track.</p> <p>On my project I have a row of images, showing previews of images. Kind of a image gallery.</p> <p>I want to be able to click onto the smaller images and then get simple Modal to display the ful...
3
1,264
Array doesnt fill/map() right React
<p>I'm trying to map an array but I think it filled wrong because it gives <code>undefined</code> for the things I added a few things but they come up as <code>undefined</code> for some reasons</p> <p><a href="https://i.stack.imgur.com/w2Fic.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/w2Fic.png" ...
3
1,098
Checking Status Code in Angular 5
<p>I am using .NET Core 2.1 API in my Angular APP</p> <p>Below is my API</p> <pre><code>[HttpPost("[action]")] public ObjectResult CheckLogIn([FromBody] LogIn model) { try { UserInfo user = new UserInfo(); using (IDbConnection db = new SqlConnection(configuration.GetCon...
3
1,103
Spacing issue with image placed in table - HTML and CSS
<p>I'm building a table for my website, and I'm trying to place a logo inside of a data cell. The issue is that whenever I add the picture, the margins go really weird and I can't figure out why spacing is added. I tried to remove the padding and margins on the image, and the cell itself, but nothing fixes it.</p> <p>...
3
1,549
Remove sticky navbar while scrolling down using UIKit 3
<p>I'm using the UIKit CSS framework. I'm trying to hide a sticky navbar. I want to use a sticky navbar in one page and the same navbar to remove sticky in another page navbar section.</p> <p>I tried the following UIKit code for this purpose but I've been unable to do so. Please give me some suggestions.</p> <p><div ...
3
1,410
Socket - server does not receive client messages
<p>I'm new in client/server programming so I tried to write a simple chat program peer-to-peer so each program has it's own client and server and the programs are directly connected something like this.</p> <pre><code> Program1 Program2 |----------| |----------| |--Client--|-----------...
3
1,775
browser independent file io in javascript
<p>I have searched religiously here and elsewhere online for resolution to my problem to no avail. I have found many code snippets with samples from javascript to jquery that claim to be able to create and write to a txt or html file, but none of them have worked for me. Here is my issue... </p> <p>I have a nice littl...
3
1,569
Binary search in Java - learning it "my way"
<p>So I'm trying to teach myself how to implement a binary search in Java, as the topic might have given away, but am having some trouble.</p> <p>See, I tend to be a little stubborn, and I'd rather not just copy some implementation off the internet.</p> <p>In order to teach myself this, I created a very (VERY) rough ...
3
1,143
Masonry shows at the bottom of a page when using tab content menu
<p>i am new in coding. Please don't blame me, if i failed with code.</p> <p><strong>The problem</strong></p> <p>I am using Masonry and tab content menu plugins. In first, active menu, content displays perfectly, but when i am clicking second or third menu item, content displays at the bottom of the page (or there, wh...
3
1,822
Triangular images in a shape of a diamond
<p>I'm pretty new at this, and I am having some issues with positioning some images the way I want it. This is what I want:</p> <p><img src="https://i.stack.imgur.com/amrnm.jpg" alt="enter image description here"></p> <p><div class="snippet" data-lang="js" data-hide="false" data-console="false" data-babel="false"> <d...
3
2,907
SpringOrm-Hibernate 4 to 5 migration issue - need to mutate metadata before building sessionFactory
<p>I'm trying to upgrade from Hibernate 4.3.11 to 5.4.x with Spring-Orm 4.3.29. As part of the upgrade, I need to migrate existing custom logic that is dependent on NamedSQLQueries retrieved from Hibernate Configuration class. This custom logic mutates the NamedSQLQueries and updates back to the original Map before bui...
3
1,244
Filter does not show as I expected
<p>I made a table that displays values from an array, to which I added a filter. The table is paginated with a maximum of 5 records per page.</p> <p>The problem occurs when I apply the filter. For example, if you do a search for the term "ora" will have three records, one on each page.</p> <p>How do these results to ...
3
2,034
I need to Incorporate certain Google Chart in a single page. How do i control the spacing?
<p>Below is the Javascript for the Google Chart. I have added the below in my html then write the code for html using table I have incorporated every single id. but the sapaces becomes too much from top to bottom and left to right between each chart. How can i control this even though i have not given any css property ...
3
1,384
Web Scraper freezes on digital ocean vps
<p>I have this scraper build with asyncio and httpx and it triggers on POST request where a user uploads the list of keywords as a csv file. Everything working fine locally but it hangs up when I try to do 50+ keywords on digital ocean server.</p> <p>my api code fragment:</p> <pre><code>import fastapi as _fastapi from ...
3
4,582
Keycloak 15.0.2 - UserFederation and AccessToken mismatch on first run
<p>As the title says, I'm developing a Custom User Storage Provider (here forth SPI) with Keycloak 15.0.2.</p> <p>I’m having trouble sorting an issue where the very first access token that is issued, does not match the expected format (is missing some fields) but also seems to be issued for a different user, if I am to...
3
1,100
Deserialise JSON to more than one data type (Geospatial system)
<p>After scouring SO and Google for answers I'm at a loss, so hoping someone can help me on this one!</p> <p>I have a project that consumes data from a 3rd party API. The data is a JSON message containing asset locations (lat and lng).</p> <p>But the API can support polygons and points (shown respectively below):</p> <...
3
1,635
How can I have both receptionist name and doctors name in the same Query output?
<p>Generate a list of all appointments in alphabetical order by patient name and by latest date and time for each patient. The list should also include the doctor scheduled and the receptionist who made the appointment.</p> <p>This is my query so far:</p> <pre><code>SELECT PatientLastName, PatientFirstName, Date_Time A...
3
4,229
Can't get an Entry object which is a fraction
<pre><code>import tkinter as tk import fractions def tests(parameters, root): print(parameters[0]) root.destroy() return None class ScrolledFrame(tk.Frame): def __init__(self, parent, vertical=True, horizontal=False): super().__init__(parent) # canvas for inner frame self._ca...
3
1,428
Frustrating App Crash
<p>Having previously had my application working <em>perfectly</em>, it now continually crashes now that I have attempted to add extra, but almost identical functionally. By extra functionality I mean Edit Texts, Spinners, etc. This is hugely frustrating, as it clearly is something very small that seems to be the issue...
3
8,705
How to send JSON to PHP through AJAX?
<p>I've tried over and over and it never works. I don't know how to receive the JSON on the server side. </p> <p><strong>JS</strong></p> <pre><code>function newReport_compilation(){ ... return JSON.stringify(formData); } var formData = newReport_compilation(); //takes all values from my form ... $("#newReport_submi...
3
1,498
Android ListView doesn't populate
<p>This is simple Android project that I did. I get no warnings or errors while running. But the ListView doesn't get populated. I don't understand what's going wrong. </p> <p>Since I dont' understand where is the exact problem and copy-pasting all the code won't help, here is my project code repository: <a href="http...
3
3,603
make elements overflow on only right side
<p>**I want first element to stay right where it is. Second element should scroll when screen resizes. fruits should not get hide under location. Everything works fine until window resizes to 600px. when window resizes it overlaps the first element. I set it to overflow-x scroll. that's what I want but the second eleme...
3
1,047
How to have two editable TextBoxes in Combobox content template?
<p>I want to have two <code>TextBoxe</code>s in <code>ComboBox</code> template as shown in the image below:</p> <p><a href="https://i.stack.imgur.com/FTGOB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FTGOB.png" alt=""></a></p> <p>I have modified control template from <strong>MSDN</strong>. This...
3
16,962
Improve SQL query to find range between start and end date
<p>I'm working with a database called <code>international_education</code> from the <code>world_bank_intl_education</code> dataset of <code>bigquery-public-data</code>.</p> <pre><code>FIELDS country_name country_code indicator_name indicator_code value year </code></pre> <p>My aim i...
3
1,049
RegEx, look for URL's where it does not start with ="
<p>I am trying to build a function to find URL's in strings and change them into links. But I do not want to find URL's that is already inside a HTML tag (Like <code>&lt;A&gt;</code> and <code>&lt;IMG&gt;</code> as examples).</p> <p>In other words the RegEx should find this and replace it with a link:</p> <pre><code>...
3
1,283
How to set a constant transparency in a pdf for a radial gradient
<p>I am using javascript to create pdfs with gradients and transparency. I am using Firefox as my browser. It works with a linear gradient, but fails with a radial gradient. The only difference is these lines, with the linear coming first:</p> <pre><code>/linear0 scn /radial0 scn /ShadingType 2 /ShadingType 3 /Coord...
3
1,851
Pyspark how to multiply one column with the result from another column -count in dataframe?
<p>I have this DF <code>salesDF</code>:</p> <pre><code>+-----------+-------------+----------------+----------------+----------+------------+----------------+---+----------+-------------------+ |customer_id|customer_name| email_address|shipping address|product_id|product_name|product_Category|qty|unit_price| ...
3
1,260
Using other Class C++ Primer 5th Edition
<p>i somehow have alot of Errors, when i try to implement another given class in the Book (<a href="https://github.com/jaege/Cpp-Primer-5th-Exercises/blob/master/ch1/Sales_item.h" rel="nofollow noreferrer">https://github.com/jaege/Cpp-Primer-5th-Exercises/blob/master/ch1/Sales_item.h</a> this one). Now if i try to comp...
3
3,925
How can I Copy Data only if Header is "Name"?
<p><img src="https://i.stack.imgur.com/aDWI5.png" alt="enter image description here" /></p> <p>I have workbook with around 50 sheets in it, some of random sheet have Employee names in it. I want all the name to be copied in sheet 1 (A1)</p> <p>Please note that data is not in table format.</p> <p>I want Macro to run in ...
3
1,278
Java Get MulticastSocket.receive to Throw ClosedByInterruptException
<p>I have some code that reads data from a multicast socket until a user-defined end time. I would also like to stop reading data if the thread is interrupted via a call to <code>Thread.interrupt</code> (or by any other user-initiated action you can come up with). I can't figure out how to get notification when the t...
3
1,220
numpy matrix multiplication and power is not correct
<p>I write a some functions to compute a Fibonacci numbers. I discovered that some values of the <code>fib2</code> and <code>fib3</code> are not equal with others.</p> <p>To reproduce to the following:</p> <p></p> <pre><code>import numpy as np def fib1(n): if n == 0: return 0 a, b = 0, 1 for i in range(...
3
1,423
Using arma::solve with RcppParallel: how to avoid stack imbalance?
<p>I want to use arma::solve within a rcppParallel worker. The problem is that the code results in a crash of R, probably due to stack imbalance.</p> <p>To avoid stack imbalance issues one should use RMatrix objects instead of arma::mat objects in the worker as far as I understand the decription of the rcppParallel pa...
3
1,217
WCF - Error handling depends on the binding used?
<p>Is there some difference in the way how the exceptions are handled in regards of the binding used?</p> <p>I'm getting different results if I use WSHttpBinding or BasicHttpBanding. </p> <p>For example, this is my error handling routine in the client side:</p> <pre><code>//MyClient client = new MyClient("WSBinding"...
3
1,024
How to organize array of dictionaries based on the value of a key within them?
<p>I have an array of information stored as follows:</p> <pre><code>( { actual = "&lt;null&gt;"; code = "AUTO.US"; date = "2019-12-31"; difference = "&lt;null&gt;"; estimate = "-0.12"; percent = "&lt;null&gt;"; "report_date" = "2020-03-27"; }, ...
3
1,312
TclError: no display name and no $DISPLAY environment variable
<p>I have developed my own photobooth software using a Raspberry Pi and a DSLR cam, as well as Python, TkInter and gPhoto library. The photobooth software is pretty flexible, because of using a config file and supports serveral types of input buttons and leds as well as live preview and random photo gallery (as a scree...
3
8,972
Select form element inner text spacing
<p>I found this inconsistent behaviour on the select element between -webkit and other browsers. The spacing for the text inside the element isn't consistent with the other input elements. (See example). The selects have an extra <strong>~2px of spacing on the left</strong>. Thus not aligning horizontally with the inpu...
3
1,637