text
stringlengths
15
59.8k
meta
dict
Q: UML-XMI to XML conversion using XSLT I am trying to convert .UML (in XMI format) file to XML file by writing xslt code. I am novice at this and would be happy if you can help me understand better. Currently I am only trying to read 1 or 2 elements the input and print an XML output with those elements. XMI-UML input...
{ "language": "en", "url": "https://stackoverflow.com/questions/32009214", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Restrict character/string/word in input My function, addthisTxt, is not checking the length. It should not exceed 11. Below is what I have tried so far; I'd like to keep on adding text until it reaches the max length, otherwise it should restrict the user from adding more. HTML <input type="checkbox" name="chkbxr" v...
{ "language": "en", "url": "https://stackoverflow.com/questions/45080436", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Twitter iframe widget remove scrollbar Been trying to figure out how to remove the scrollbar in the iframe twitter widget. I know I can't do it with css so my next look was with jquery tried the following but doesn't seem to work $("iframe").ready(function () { $(".stream", this).css("overflow-x", "hidden"); });...
{ "language": "en", "url": "https://stackoverflow.com/questions/15626846", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: UIPanGestureRecognizer manually start gesture I have a bunch of views setup on the screen and by using touchesBegan: and touchesMoved: overrides in my main view, I let the user drag around the screen and track the position. When a user hovers over one of the views, I want that view to start a pan gesture recognizer ...
{ "language": "en", "url": "https://stackoverflow.com/questions/24913019", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Is it possible to show a message text on the chart of Billboard.js? I'm working with Biilboard.js, a library which is based on D3. I created a chart and I want to be able to show a message on it, for example if Y-axis is greater than 100 or anything like this, doesn't matter the condition. This is an example of what...
{ "language": "en", "url": "https://stackoverflow.com/questions/48784703", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Bootstrap-Table loading by Json I'm trying to reproduce it this example, but when I download files and try to play in local, not shown me the table, only show me the header, the title an two buttons (learn more and delete) http://issues.wenzhixin.net.cn/bootstrap-table/index.html HTML: <table id="table" da...
{ "language": "en", "url": "https://stackoverflow.com/questions/34771466", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is this the "good" way to implement a 6502 CPU emulator in JAVA? Wanting to make sure I won't have to go back and redo large chunks of code... I have each opcode as a value in an enum that implements Runnable. Is there a more efficient way that I should do this or am I on the write track to getting something that ru...
{ "language": "en", "url": "https://stackoverflow.com/questions/40708150", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Why is jQuery toggleClass not removing a class? I have made a Skills accordion but I now want to create a button to toggle all the skill sections. When I am doing this, the jQuery isn't removing/adding the class when it needs to on the .accordion-trigger-all. I originally use .click() but then I changed to .on("clic...
{ "language": "en", "url": "https://stackoverflow.com/questions/65850916", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Compiler error for lambda expression public ICommand ChangeLangCommand => new DelegateCommand(this.ChangeLangClick); I get this compiler error, marked on the => arrow: Error 1 ; expected Am I using the wrong compiler version somehow? How can I check this? A: This is a C# 6.0 feature called expression bodied p...
{ "language": "en", "url": "https://stackoverflow.com/questions/39225846", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to stop the location of one grid element from changing due to the update of the content of another grid element in python tkinter? I have written code for a small python tkinter application which goes as follows import tkinter as tk from tkinter import * import tkinter.filedialog as fdialog class karl(Frame): ...
{ "language": "en", "url": "https://stackoverflow.com/questions/56199270", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: django.db.utils.IntegrityError: NOT NULL constraint failed: pages_add_music.upload error I wrote a code to upload images of music and it works ,but when I try to edit older posts (I hadn't add img field yet) It shows following error: django.db.utils.IntegrityError: NOT NULL constraint failed: pages_add_music.upload...
{ "language": "en", "url": "https://stackoverflow.com/questions/72341413", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Get data from XML file with javascript I'm learning how to do this with the help of some tutorials but this code is not working. The browser is not displaying anything from the XML file. Is there anything wrong with my code? Here are the codes: <?xml version="1.0"?> <Company> <Employee category="technical"> <F...
{ "language": "en", "url": "https://stackoverflow.com/questions/26836946", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Create Mojave Cocoa window programmatically in Objective-C I'm trying to create a minimal application in order for me to start a game engine from scratch. Here is the code: #import <Cocoa/Cocoa.h> int main (int argc, const char * argv[]){ NSWindow *window = [[NSWindow alloc] init]; [window makeKeyAndOrderFr...
{ "language": "en", "url": "https://stackoverflow.com/questions/54750924", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Should and be avoided at all costs in web design? I continuously find places where I need to use the <br /> tag because CSS can't do what I need. Isn't the <br /> considered part of the "design" and not part of document structure? What is the acceptable usage for it? Should the same rules also apply to the <hr />?...
{ "language": "en", "url": "https://stackoverflow.com/questions/462619", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "44" }
Q: Firebase getDownloadURL From Storage Unable To Set Img Src I am trying to replicate the results of this question here. I am able to call getDownloadURL() on a valid database child, but the result it returns cannot seem to be set to an IMG's src. This is the code I am currently using to try and grab the download URL...
{ "language": "en", "url": "https://stackoverflow.com/questions/41326493", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to fix "invalid key format" while read public or private key from file? I have created the public and private key . The public and private key generated from php code : <?php require __DIR__ . '/vendor/autoload.php'; use phpseclib\Crypt\RSA; $rsa = new RSA(); extract($rsa->createKey()); $rsa...
{ "language": "en", "url": "https://stackoverflow.com/questions/59263160", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: css floating divs minwidth without overlapping Well I am making a "simple 3 column layout", the basic setup are two fixed width columns and a (center) column that stretches to fill the remaining width. Now there is a small "addon" to that simple layout: I wish to have a defined minimum width for the center column, c...
{ "language": "en", "url": "https://stackoverflow.com/questions/47191629", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Flutter : Weird SystemUIOverlayStyle bug I used SystemChrome & AnnotatedRegion to change some default colors for the status & navigation bars but both didn't work and two problems are found now : First : The navigation bar background color never changes whatever I do. I thought that the phone I am testing my app on ...
{ "language": "en", "url": "https://stackoverflow.com/questions/58542818", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Xcode: show documentation for my custom classes How can I force Xcode to show my own documentation for custom classes, methods, etc.? I'm used to Java and Eclipse, which shows me documentation for my classes as shown here: How can I achieve the same in Xcode? Are there special comments that Xcode can recognize and ...
{ "language": "en", "url": "https://stackoverflow.com/questions/6958413", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "49" }
Q: try/catch is not catching exception I'm using the google_sign_in package and I'm a bit new to error handling. I surrounded two lines in a try/catch statement and I get the exception in VSCode even though I check for PlatformExceptions. The line that gives me the error is where I set the googleSignInAccount variable....
{ "language": "en", "url": "https://stackoverflow.com/questions/60608407", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Github CLI or API, can I see which commit a Github Action workflow was run on? Using Github's CLI tool, I can see a Github Action workflow's log by gh run view [ID] --log Submitting the ID of a run, this returns the run's log. Now, if I don't have the ID, is there any way to find out from a commit SHA, if there are...
{ "language": "en", "url": "https://stackoverflow.com/questions/75295118", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Sql query, how to select the clients that has never stayed on a room that cost 5000? This is the database room(room_id, price) client(client_id, name) stayed(StartDate, EndDate, room_id, client_id) I want to select all the clients' names that have never stayed in a room that has a price above 5000. I tried this cod...
{ "language": "en", "url": "https://stackoverflow.com/questions/58261210", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How can I know the IP address of my iPhone simulator? How can I know the IP address of my iPhone simulator? A: It will have the same IP addresses as the computer you’re running it on. A: Jep, like Todd said, the same as your machines IP. You can also simply visit http://www.whatismyip.com with mobile Safari or you...
{ "language": "en", "url": "https://stackoverflow.com/questions/5667802", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Escape dash sign of bash history command On my Ubuntu system, I would like to use bash history command to remember some commands, but when I enter command like: history -s "-t tag_name" bash report error: bash: history: -t: invalid option history: usage: history [-c] [-d offset] [n] or history -anrw [filename] or h...
{ "language": "en", "url": "https://stackoverflow.com/questions/35480054", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to expand div in a HTML page I'm working on a browser app. I have read about a couple of dozen pages about the DIV tag. I just can not get it to work. I know I should use CSS but I will incorporate that at the end after I get some other things done. Basically I want a header and a footer. Then a fixed width ...
{ "language": "en", "url": "https://stackoverflow.com/questions/29306366", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Unify and simplify MySQL commands I did some MySQL commands, however it was a bit slow to execute because there are three commands executed at the same time. How can I unite all in just one command and simplify the code to make it faster? UPDATE bidbutler b LEFT JOIN auction a on b.auc_id=a.auctionID LEFT JO...
{ "language": "en", "url": "https://stackoverflow.com/questions/50054410", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Pyspark to connect to postgresql I'm trying to connect to a Posgresql database in Databricks and I'm using the following code: from pyspark.sql import SparkSession spark = SparkSession.builder.config("spark.jars", "path_to_postgresDriver/postgresql_42_2_14.jar").getOrCreate() driver = "org.postgresql.Driver" data...
{ "language": "en", "url": "https://stackoverflow.com/questions/75327651", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Microsoft SQL Server stuck at "Install_SQLSupport_CPU64_Action" While installing SQL Server 2017 Developer Edition, I got stuck at "Install_SQLSupport_CPU64_Action", this happened to me for the second time, once at work and once at home. After searching online I found no solution. A: The solution: You will need to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/54380363", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "23" }
Q: Convert reference to item to slice of length 1 I have a &X. How can I convert this to a &[X] of length 1? std::slice::from_raw_parts should work, but it is unsafe. Is there a safe function that I can use to do this conversion?
{ "language": "en", "url": "https://stackoverflow.com/questions/44629021", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Wrap if long not working in android studio I have custom settings for my android projects. I cannot get my code to wrap, whether I use wrap if long or always wrap. I have included screenshots. I have used the settings for the android xml, the xml, the java, the margin. The Margin: It still extends past the margi...
{ "language": "en", "url": "https://stackoverflow.com/questions/30963489", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: XHR request for Image Fails On Second Request in Safari I am storing image assets on S3 and requesting them using an XHR. I have a CORS policy file on S3 that looks like this: <?xml version="1.0" encoding="UTF-8"?> <CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"> <CORSRule> <AllowedOri...
{ "language": "en", "url": "https://stackoverflow.com/questions/16760570", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Rails ajax form, does its job but still tries to redirect I have a remote form for @vote, which submits a choice id. I simply want to render a partial instead of redirect it after the successful create action. The action is successful, the vote is created, my create.js.erb is not reached and it gives a RoutingError....
{ "language": "en", "url": "https://stackoverflow.com/questions/42315737", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to open hyperlinks in excel without mouse-click; is there any shortcut key/Keys I have many hyperlinks in a column of excel-sheet. Is/Are there any shortcut key/Keys so that after going to each cell(using keyboard) I can open those in browser without using mouse-click? A: Press the menu key and then press 'O' ...
{ "language": "en", "url": "https://stackoverflow.com/questions/28188425", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "18" }
Q: How can I make matplotlib mark_inset display line on top of the graph? I have this code ax = plt.subplot(222) plt.plot(time_list, data[1], color='red') plt.plot(time_list, y_offset, color='blue') plt.axvline(x=0, color='black') plt.axhline(y=0, color='black') axins = zoomed_inset_axes(ax, 4.5, loc=4) axins.plot(tim...
{ "language": "en", "url": "https://stackoverflow.com/questions/32423187", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: 8 bit floating point binary to decimal This question is similar to the question asked here: Floating point conversion for 8-bit floating point numbers. The marked answer is good but I am missing what a few of the symbols mean and some of the math completed in between the lines. If you could, please walk me through t...
{ "language": "en", "url": "https://stackoverflow.com/questions/30249620", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Oracle pl/sql reference(return?) cursor/declared cursor Is there a way to do something like this? Output a cursor's fetched data into a refcursor without stuffing it into a table first? create or replace procedure someprocedure ( rc1 in out adv_refcur_pkg.rc) -- this is defined below as v_class_year varchar(10); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/19427897", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: DocumentViewer GoToPage() Issue I have a little a problem with the WPF DocumentViewer. I'm displaying an XPS file using the DocumentViewer. I want to navigate the XPS document to a certain Page but it navigates to the wrong page number during the initializing of the window. This is my code: public partial class Win...
{ "language": "en", "url": "https://stackoverflow.com/questions/19791017", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What is the mathematical way to determine an angle from two given true bearings? Given that I have two true bearings as a start bearing 315 degrees and an end bearing 45 degrees, is there a better way to determine the angle between the two true bearings? The complication comes in when the start bearing is greater t...
{ "language": "en", "url": "https://stackoverflow.com/questions/61900967", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Disable the input value I have an input field. In which I want to fix a value. I am able to fix the value by putting readonly but it's not passing the value which I have put as fixed. what I am doing is:- <input name="txt_zip_code" class="z-con-input adj-z-con-input" style="background:#eee" type="text" maxlength="...
{ "language": "en", "url": "https://stackoverflow.com/questions/26894349", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: TYPO3 Inline Relational Record Editing (IRRE) I created a new content element which adds a field called heroslider to tt_content. The TCA looks like this: 'heroslider' => [ 'config' => [ 'type' => 'inline', 'allowed' => 'tx_ext_domain_model_heroslider_item', '...
{ "language": "en", "url": "https://stackoverflow.com/questions/53522268", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: TYPO3 9.5 Speaking URL - How to rewrite/redirect former RealUrl pages suffixed .html How can I permanently rewrite or redirect former from realurl suffixed .html pages to the new implemented URL? So far I didn't see any solution in the API Overview -> Site Handling. Or do I have to do this in the .htaccess file? I j...
{ "language": "en", "url": "https://stackoverflow.com/questions/53882462", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Stata calculate % change between years I have the following columns in my data Firm - revenue - industry - year I want to calculate the percentage change in total revenue for each industry between 2008 and 2015. I tried: by industry: egen tot_2008 = sum(revenue) if year == 2008 by industry: egen tot_2015 = sum(reven...
{ "language": "en", "url": "https://stackoverflow.com/questions/41122322", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to make visual studio always view commit details in a new tab in git changes? It opens commit details in a small window inside git history and it's very inconvenient, because it's too small to see anything. Clicking "open in a new tab" every time is annoying. Is there a way to make visual studio always open it i...
{ "language": "en", "url": "https://stackoverflow.com/questions/69378782", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: in robot framewerk text edit using selenium library This is an issue I'm facing while automating my test case via robot framework, I'm trying to click on the Action column of 3rd row in the below table (screenshot below) The Xpath I'm using is as below Click element xpath=.//table[id="mylogiusers"]/tbody/tr[3]/...
{ "language": "en", "url": "https://stackoverflow.com/questions/48704750", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Best way to implement CDN in ASP.NET I need to implement CDN in an ASP.NET project. The best Idea I could come up with is creating a custom HttpModule which will handle the PostRequestHandlerExecute event. I'm replacing all the static URLs domain with the CDN's zone url before the response is sent to the client. Her...
{ "language": "en", "url": "https://stackoverflow.com/questions/32007306", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Jquery ajax to retrive php get variable I would like to take the $id variable from an ajax form (input.php) and make it usable on the main page so I can .submit() the form using this variable in the action='ask.php?q='. Main Page: <script type='text/javascript'> $(document).ready(function(){ $('#questionSubmit')....
{ "language": "en", "url": "https://stackoverflow.com/questions/8651849", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Error message seems ambiguous without any descriptive clue I am new to transcrypt. I created a test python file,test.py def test_def(a: list): for i in range(len(a)): print(i) xx = [2, 3, 4] test_def(xx) I have python 3.9. If I run the python file, it runs and prints as expected. Running transcry...
{ "language": "en", "url": "https://stackoverflow.com/questions/68582595", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: ORA-00001 Unique constraint (string.string) violated I have two tables that are identical to each other t1 and t2, but t2 has more data than t1. I'm using this query to insert the missing data from t2 to t1. insert into t1 select * from t2 where not exist ( select * from t1 where t1.key1 = t2.key1 ...
{ "language": "en", "url": "https://stackoverflow.com/questions/15412976", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Getting error while running rails server I am migrating my web app to Microsoft Azure. When I do rails s, I am getting this log: /home/mnpatel0611/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/activesupport-4.0.0/lib/active_support/values/time_zone.rb:282: warning: circular argument reference - now /home/mnpatel061...
{ "language": "en", "url": "https://stackoverflow.com/questions/30522126", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Order by a value returned from function called in Stored Procedure MYSQL I want to order by dist : dist is a double value returned from function called isNeighbour It throws error as dist is undefined : Unknown column 'dist' in field list DELIMITER $$ DROP PROCEDURE IF EXISTS `connectarabs`.`maxEdges` $$ CREATE DE...
{ "language": "en", "url": "https://stackoverflow.com/questions/12140287", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Return data from nested array I'm trying to get some data from Wikipedia API. I found this project https://github.com/donwilson/PHP-Wikipedia-Syntax-Parser but I cannot figure out how to output the infobox entries in a loop, because the array is in an array which is in an array. The array code [infoboxes] => Arr...
{ "language": "en", "url": "https://stackoverflow.com/questions/23896210", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to forecast few periods ahead,a univariate timeseries using support vector regression I have the following data: head(df) pce pop psavert uempmed unemploy 507.8 198712 9.8 4.5 2944 510.9 198911 9.8 4.7 2945 516.7 199113 9.8 4.6 ...
{ "language": "en", "url": "https://stackoverflow.com/questions/42268035", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Group like JSON objects into arrays I have a model returned by a library in the following format: var givenData = [{"fName": "john"}, {"fName": "mike"}, {"country": "USA"}] How do I group the "fName" together and add '[]' to get: { 'fName[]': ['john','mike'],'country[]': ['USA'] }; **Note country and fName are not...
{ "language": "en", "url": "https://stackoverflow.com/questions/42077841", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to update users that have 'old' banners? In the past users have uploaded banners freely without validation. Just recently we rolled out validation with banners. How do we update user records that have OLD banners? class User < ActiveRecord::Base require 'carrierwave/orm/activerecord' mount_uploader :banner, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/9598548", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Automating file upload using Selenium and pywinauto I am trying to automate a file uplad in a form. The form works as follows: - some data insert - click on add attachment button - windows dialogue window appears - select the file - open it I am using python, Selenium webdriver and pywinauto module. Similar approach...
{ "language": "en", "url": "https://stackoverflow.com/questions/40040564", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Convert double to string quickly observing given precision I have a C++ program using SDL. During rendering, I need to draw some graphics components. I sometimes need to convert double variables, rounded to one decimal, to std::string. For this, I'm currently using a ostringstream object and it works fine. std::ostr...
{ "language": "en", "url": "https://stackoverflow.com/questions/34744591", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: confusion about array and object in JavaScript I want format like that "attechent":[{ "name":xyz, field: [ { title: 'a' }, { title: 'b' } ] } ] code->> var field=[] var obj1={"title":"a"} var obj2={"title":"b"} field.push(obj1) field.push(obj2) co...
{ "language": "en", "url": "https://stackoverflow.com/questions/42607050", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Pseudo-random Lognormal values I'm trying to generate pairs of random values from two lognormal distributions - the catch is that one of them must be less than the other. For example: a1 <- log(47.31) b1 <- sqrt(2*log(50.84/47.31)) a2 <- log(47.31) b2 <- sqrt(2*log(59.34/47.31)) x1 <- rlnorm(1,a1,b1) x2 <- rlnorm(1...
{ "language": "en", "url": "https://stackoverflow.com/questions/11146488", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What is which in Perl? When I run perl -e 'which("clang")' in Windows Command Prompt I get an empty line, but on Linux I get: Undefined subroutine &main::which called at -e line 1. I am asking because I am trying to figure out why which does not work in OpenSSL build script: # see if there is NDK clang on $PATH, "...
{ "language": "en", "url": "https://stackoverflow.com/questions/74098951", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Capybara feature test (js: true, React) fails because image element forced to make request I have a form page that renders react components. These components render images that have been uploaded to the local environment (normally they are uploaded to s3). Originally, I setup my test environment path to point to ins...
{ "language": "en", "url": "https://stackoverflow.com/questions/50032430", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: jQuery on hover out the element still retains the hovered class. This class styles should be removed when the mouse is hovered out I want the login-btn to remain in its hover state when mouse is hovered over .login-content. I have already attempted at this, and for now it shows and hides the div on hover, but the lo...
{ "language": "en", "url": "https://stackoverflow.com/questions/16311239", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Exiting program for any input that is not a list My goal is to create a little program that converts angle from radiant to degree and vice-versa. I need the program to close with no error message from python if the user enters the information to convert in the wrong format. After assigning the variable ‘angle’ to bo...
{ "language": "en", "url": "https://stackoverflow.com/questions/37886159", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Problem with "extra_context" in a login view I'm looking at login views rn but have troubles trying to redirect using the "next" variable that I'm trying to assign a value to inside of "extra_context" dictionary. Overriding "extra_context" in a custom view that inherits from "LoginView" also doesn't work. Redirectin...
{ "language": "en", "url": "https://stackoverflow.com/questions/72006025", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Add buttons to the windows taskbar thumbnail JavaFX? This question has been inactive for over a year now. I still don't have a solution for my problem. I edited this to clarify my problem and bring new attention to it. If you use Windows you probably know the small preview image (thumbnail) that is shown when you ho...
{ "language": "en", "url": "https://stackoverflow.com/questions/57117955", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Returning arbitrary data types in golang I have a simple golang routine that uses database/sql to open a connection to my Postgres DB and does some stuff package main import ( "fmt" "database/sql" _ "github.com/lib/pq" "log" ) const ( DB_USER = "my_user" DB_NAME = "my_postgres_db" ) // The return ...
{ "language": "en", "url": "https://stackoverflow.com/questions/37108480", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Borders of text boxes not getting painted after validation fails I am just following a ASP.NET MVC book example and for validation we have added those [Required] attributes to the model and it works but now it has added a style sheet to highlight the fields that have issues as well. Here is how it looks in my IE: N...
{ "language": "en", "url": "https://stackoverflow.com/questions/24471092", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do I display errors on login modal form when a user enters invalid credentials in Laravel 5.6? In Laravel 5.6 I am using it's default authentication feature. However I have implemented a modal to replace the default login form. I am trying to keep a login modal form open and display errors upon failed login atte...
{ "language": "en", "url": "https://stackoverflow.com/questions/50664441", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to decompress gzipstream with zlib Can someone tell me which function I need to use in order to decompress a byte array that has been compressed with vb.net's gzipstream. I would like to use zlib. I've included the zlib.h but I haven't been able to figure out what function(s) I should use. A: You can take a loo...
{ "language": "en", "url": "https://stackoverflow.com/questions/14688296", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: memcpy() not working as expected when copying pointers I want to copy the content of a char **pointer to another pointer. My attempt was: void test(char **arr, int len) { printf("1: "); printArr(arr, len); char ***res = malloc(sizeof(char **)); res[0] = malloc(sizeof(char *) * len); memcpy(&res[...
{ "language": "en", "url": "https://stackoverflow.com/questions/66646357", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Reading the data from socket is currupted in following condition? I am reading data from a socket packet by packet and writing into another buffer to combined all the data. BOOL _ReadPacket(PBYTE BufferRead, DWORD &Length, SOCKET Socket) { WSABUF Buffer; DWORD Flags = 0; int Result = 0; FILE *file; ...
{ "language": "en", "url": "https://stackoverflow.com/questions/17730052", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: The module 'app' is an Android project without build variants I am getting below error while importing android project. Error:The module 'app' is an Android project without build variants, and cannot be built. Please fix the module's configuration in the build.gradle file and sync the project again. Gradle file ...
{ "language": "en", "url": "https://stackoverflow.com/questions/49834961", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "38" }
Q: AFrame and three.js lookat function for child object I want to make a child object to look at the camera position. In my code, the a-text object is child object of a-entity that is a sphere. I set the lookat for a-text object to camera position. but it works wrong behavior. I found the reason but no idea for how to ...
{ "language": "en", "url": "https://stackoverflow.com/questions/62861439", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Crystal Reports Cross-tab overlapping issue I need some assistance to diagnose an issue with crystal reports overlapping occurs in one of my reports where Cross tab is being used inside sub-report , the crosstab overlaps the next section, this happen just when we run the report through our web site, while it is work...
{ "language": "en", "url": "https://stackoverflow.com/questions/32585625", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Variables set of three? I'm starting to learn Python from a tutorial and I'm not sure how this bit of code works. So we have a return for jelly_beans, jars, crates in the function; however, a little below we see a new set of variables named beans, jars, crates. Does this mean that jelly_beans, jars, crates from the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/27033161", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Multiplying a certain element in a dataframe, given that certain element is the same as the filename of a CSV file in R I am trying to solve big data problems and this involves 2 different CSV files. If the filename of CSV1 matches a certain element in CSV2, I will multiply each element of CSV1 to that certain eleme...
{ "language": "en", "url": "https://stackoverflow.com/questions/60824792", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Submitting request to https returns http I'm creating and angular app that uses a django backend accessed as a Api. The link for my backend is https, and one of its main purposes is to act as a database for image storage. I am trying to grab the URLs in the backend by using http calls from my front end. It's not wo...
{ "language": "en", "url": "https://stackoverflow.com/questions/53767491", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: I am having a trouble for insert an csv file data to mysql table I want to insert an csv file data to mysql database.The data is inserted but the values are in readable format.So please help me to insert an original csv data to mysql databse. These are my php content: <?php include "config.php"; if($_FILES[csv][si...
{ "language": "en", "url": "https://stackoverflow.com/questions/25581163", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: java.security.cert.CertificateException when connecting to server with multiple certificates I'm trying to create SSL connection to a website (https://www.otten-markenshop.de/), and using browser or curl it works, but neither wget, no Java manages to connect. I am mostly interested in why does Java code fail. Here ...
{ "language": "en", "url": "https://stackoverflow.com/questions/24061279", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: App.config Data Source Relative Path? This is the connection string to a local database on my pc: <connectionStrings> <add name="DataEntities" connectionString="metadata=res://*/Data.csdl|res://*/Data.ssdl|res://*/Data.msl; provider=System.Data.SqlServerCe.4.0;provider connection string=&quot; Data Source...
{ "language": "en", "url": "https://stackoverflow.com/questions/31733056", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to open String class to rewrite to_s method I want to rewrite the to_s method so that I can print the money in number_to_currency format. How do I do it? Is there any way to print all Integer or Float variables in number_to_currency format without calling number_to_currency method? I ran this code in the console...
{ "language": "en", "url": "https://stackoverflow.com/questions/23320876", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why does gets work even when I have not allocated memory to it? I recently answered a question here in SO where the problem was to input a few sentences of code and print it. My code is this: #include<stdio.h> int main() { clrscr(); int line, i; char (*string)[100]; printf("How many line?\n"); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/30961881", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-3" }
Q: why console.log(window) in js not working on regular visual studio's console? when I try to implement the below code, and I try to run on chrome. It gives me the answers what I expected. But when I compiled it inside my IDE(visual studio code), it gives me error console.log(window) // or console.log(this) /// Abov...
{ "language": "en", "url": "https://stackoverflow.com/questions/57209716", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Are C++ recursive type definitions possible, in particular can I put a vector within the definition of T? For one of my projects, what I really wanted to do was this (simplifying it to the bare minimum); struct Move { int src; int dst; }; struct MoveTree { Move move; std::vector<MoveTree> variation;...
{ "language": "en", "url": "https://stackoverflow.com/questions/6517231", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "37" }
Q: How to update two models? I have a select option and a list and I want to update the list when the option is selected. I've tried something but without success. The request to update the notes doesn't fire. See the code below. <select ng-change="timeline.selectNote()" ng-model="timeline.selectedNote" ng-options="...
{ "language": "en", "url": "https://stackoverflow.com/questions/24970779", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: build elements hierarchy with jquery I need to set deep for each ul. I do $('.topnav').find('ul').each(function(){ $(this).attr('deep', $(this).index()); }) html <ul class="topnav dropdown" > <li class="expand"> <a href="/posluhy">Top</a> <ul class="subnav"> <li class="expand">...
{ "language": "en", "url": "https://stackoverflow.com/questions/21664994", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Search for partial strings Is there a setting (or snippet) I can use to perform searches for partial string matches using apostrophe-search? For example: a search for "blue" should return the item with the title "Learning Management Blueprint". A: Looks like adding a RegExp is what is needed. In case anyone else ne...
{ "language": "en", "url": "https://stackoverflow.com/questions/40477498", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: R: Sort data by most common value of a column I am following this stackoverflow post over here: Sort based on Frequency in R I am trying to sort my data by the most frequent value of the column "Node_A". library(dplyr) Data_I_Have <- data.frame( "Node_A" = c("John", "John", "John", "John, "John", "Peter", "...
{ "language": "en", "url": "https://stackoverflow.com/questions/64707943", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Can't change modes with dynamic FormView templates I have an ASP.NET page with a FormView data-bound to an ObjectDataSource that uses dynamically generated templates to render the UI based on layout information from the application's database. I've been able to get the templates to render correctly and everything s...
{ "language": "en", "url": "https://stackoverflow.com/questions/4970563", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: PrimeNg V6 confirmationService in loop I am trying to call the confirmation service within a loop, but only the last call is being executed. Is there something that I need to change in this? for (let x of y) { if (conditionIsMet) { this.confirmationService.confirm({ message: 'Question Text',...
{ "language": "en", "url": "https://stackoverflow.com/questions/55165569", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Count number of Paragraphs excluding spaces I am currently working on a code to count the number of paragraphs. The only issue I have not been able to resolve is that spaces inbetween each paragraphs is also been counted. For instance, below example should return 3 but rather it returns 5 because of the empty carria...
{ "language": "en", "url": "https://stackoverflow.com/questions/22272590", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Action attribute that restrict action method by url pattern Is there an action attribute that allows restricting action method by url pattern? In my controller, I would like to to have two SearchOrder actions. One for editing order and one for viewing order. If the url path is /Order/EditOrder/SearchOrder/1, I wou...
{ "language": "en", "url": "https://stackoverflow.com/questions/38018661", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Define a static constexpr member of same type of a template class A similar question of non-templated class For a template class, template <typename T> struct Test { T data; static const Test constant; }; it's fine when defining a static constexpr member variable of specialized type: template <> inline con...
{ "language": "en", "url": "https://stackoverflow.com/questions/72409091", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Improve performance of slow sub query in SQL Server I have a table with 1.3 million rows. Query #1 takes 29 seconds to run in SQL Server 2016 Management Studio. Query #1: select *, (select Count(*) from [dbo].[Results] t2 where t2.RaceDate < t1.RaceDate and t1.HorseName = t2.HorseName ...
{ "language": "en", "url": "https://stackoverflow.com/questions/58940763", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Including file from PHP inside dialogbox of jQuery is misleading javascript I have 3 files (file1.php, file2.php and file3.php). Their contents are given below. When I load file1.php it shows two times the message of "Hello" in an alert box. But when I include file3.php before or after dialogbox (which is in file2....
{ "language": "en", "url": "https://stackoverflow.com/questions/6430818", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Images not loading in macOS 12 & iOS 15 Mail app Around 3 weeks ago we realized images in our newsletter were not loading when opened in macOS 12 & iOS 15 Mail. When opened in different email apps, and in different versions of macOS/iOS Mail, the images would load with no problem. Switching from hosting the images o...
{ "language": "en", "url": "https://stackoverflow.com/questions/71270176", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: extract value from text file using shell script I have used curl to get the response from the restapi and below is the response which came and which i am saving in the text file in location for example c:/rest_api/response.txt. {"@odata.context":"https://hosted.com/RestApi/v1/$metadata#Edm.String","value":"_tlCijtcS...
{ "language": "en", "url": "https://stackoverflow.com/questions/68955188", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: IntelliJ Unable to find the path specified to a file in a Junit Test I have a test in IntelliJ (package: com.company.project.testClasses, path: src/test/java/tests/TestClass.java) that uses a file in a resources folder(package: testData.testDataFile.templatevalues, path: src/test/resources/testData/DataFile.file). I...
{ "language": "en", "url": "https://stackoverflow.com/questions/46225041", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Execute code if a PowerShell script is terminated Is it possible to force the execution of some code if a PowerShell script is forcefully terminated? I have tried try..finally and Traps, but they both don't seem to work, at least when I press Ctrl-C from PowerShell ISE. Basically, I have a Jenkins build that execute...
{ "language": "en", "url": "https://stackoverflow.com/questions/35414568", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Selectively sort vector c++ I have the following vector: vector<unsigned> vec = {5, 6, 5, 4, 1, 3, 0, 4} Now I want to sort this vector lexicographically by odd indices (and if odd indices are equal, then by the even indices). Such that the sorted vector "vec" is: {0, 4, 1, 3, 5, 4, 5, 6} I know std::sort is go...
{ "language": "en", "url": "https://stackoverflow.com/questions/41829450", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Invalid Bot Configuration I am getting the below mentioned error while running the bot locally. "Invalid Bot Configuration: Access denied while invoking lambda function arn:aws:lambda:us-east-1:***********:function:dataCodeHook from arn:aws:lex:us-east-1:***********:intent:DataProcess:4. Please check the poli...
{ "language": "en", "url": "https://stackoverflow.com/questions/48564265", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }