Some Of The Best Answers From Latest Asked Questions

27

answers

SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 81

I am currently new to robot framework.I am currently using latest window version of chrome and chromedriver which is 80 but when i try to run the test it gives the message "SessionNotCreatedException:..

25

answers

error NG6002: Appears in the NgModule.imports of AppModule, but could not be resolved to an NgModule class

First time using firestore and I'm getting this error. It seems to be a problem with Ivy, from my research. I don't have a lot of experience modifying tsconfig.app.json, which is the direction I've be..

19

answers

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type undefined raised when starting react app

I'm working on a project in React and ran into a problem that has me stumped. Whenever I run yarn start I get this error: TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type ..

6

answers

error TS1086: An accessor cannot be declared in an ambient context in Angular 9

I'm learning Angular Material and I'm getting this error when importing { MatButtonModule } from "@angular/material/button". From what I read in other answers, it looks like package compatibility iss..

14

answers

TS1086: An accessor cannot be declared in ambient context

I have a thousands of this error after initial implementation nad typing in terminal ng serve my-app of and i can't resolve it. This is first time for me when i have problem like this inside angular w..

13

answers

Could not load dynamic library 'cudart64_101.dll' on tensorflow CPU-only installation

I just installed the latest version of Tensorflow via pip install tensorflow and whenever I run a program, I get the log message: W tensorflow/stream_executor/platform/default/dso_loader.cc:55] Co..

33

answers

iPhone is not available. Please reconnect the device

I'm on iOS 13.5 and using Xcode 11.4 to build on to it. I'm getting this error message: The KBlackberry is my iPhone device name. I tried restarting the device and reconnecting of course and various ..

37

answers

Xcode 12, building for iOS Simulator, but linking in object file built for iOS, for architecture arm64

Trying to get a large (and working on Xcode 11!) project building in Xcode 12 (beta 5) to prep for iOS 14. Codebase was previously Obj-C, but now contains both Obj-C and Swift, and uses pods that are..

21

answers

Target class controller does not exist - Laravel 8

Here is my controller: <?php namespace App\Http\Controllers\Api; use App\Http\Controllers\Controller; use Illuminate\Http\Request; class RegisterController extends Controller { public functi..

9

answers

Error: Node Sass version 5.0.0 is incompatible with ^4.0.0

I've created a blank React project, using the command: npx create-react-app on npm v7.0.7 and Node v15.0.1 Installed: React v17.0.1, node-sass v5.0.0, Then I tried to import blank .scss file to App ..

2

answers

xlrd.biffh.XLRDError: Excel xlsx file; not supported

I am trying to read a macro-enabled Excel worksheet using pandas.read_excel with the xlrd library. It's running fine in local, but when I try to push the same into PCF, I am getting this error: 2020-1..

1

answers

How to get AIC from Conway–Maxwell-Poisson regression via COM-poisson package in R?

Is there an easy way to get AIC for a Conway–Maxwell-Poisson regression from COM-poisson package in R? see http://cran.r-project.org/web/packages/COMPoissonReg/COMPoissonReg.pdf I am not able to f..

1

answers

Monitoring the Full Disclosure mailinglist

I develop web applications, which use a number of third party applications/code/services. As part of the job, we regularly check with the Full Disclosure mailing list http://seclists.org/fulldisclosu..

3

answers

How do I get the command-line for an Eclipse run configuration?

I have several JUnit run configurations in Eclipse that I need to replicate on the command-line in order to use a third-party analysis tool. So far I've just been writing the command-line manually by..

2

answers

R : how to simply repeat a command?

I'm trying to repeat this simple command 10,000 times (via a simple and easy solution): Tandem <- sample(OUT, size = 815, replace = TRUE, prob = NULL); mean(Tandem) Any advice would be greatly a..

1

answers

Under what circumstances can I call findViewById with an Options Menu / Action Bar item?

I am trying to obtain a handle on one of the views in the Action Bar. I have tried calling: findViewById(R.id.menu_item) but this returns null unless I call it in the onOptionsItemSelected method. ..

1

answers

I am receiving warning in Facebook Application using PHP SDK

I used the following code to configure the facebook API and my structure what to follow is also OK. But I am receiving warning like that. Warning: session_start(): Cannot send session cache limiter -..

6

answers

How much should a function trust another function

Consider the following two functions in a class called Graph. The entire source code is found here: http://www.keithschwarz.com/interesting/code/?dir=dijkstra. public void addNode(T node) { ..

1

answers

PHP array value passes to next row

I have an array building multiple instances of the following fields: <div class="checkbox_vm"> <input type="hidden" name="fk_row[]" value="<?php echo $i; ?>"> <input type..

1

answers

programming a servo thru a barometer

i have a script which gets the air pressure from a website. and i wrote this function which says if the pressure gets different value if it rains or sunny weather or else now i have a servo which s..

5

answers

need to add a class to an element

here's my code: <body> <header> <h1>Html quiz</h1> </header> <article> <h2>What color is this?&nbsp;&nbsp; #00ff00 <ul> <li> <..

2

answers

conflicting types for 'outchar'

I am a newbie to C programming. I'm learning by reading the chapters and doing the examples from the book "Teach Yourself C" by Herbert Schildt. I'm trying to run this program in Dev C: #include <..

1

answers

How can I convert this one line of ActionScript to C#?

I would like to convert this one line of code to C# code within a void: param1:Function=null I am aware that in the void, it would be like "thing here" param1, but I dont know what "thing here" wou..

1

answers

Microsoft Advertising SDK doesn't deliverer ads

So I have a Windows Phone solution that has an ad in it. When my Solution References Microsoft.Advertising.SDK Advertising.Mobile Advertising.Mobile.UI Everything works fine and I get ads. Unfortu..

2

answers

Using Lato fonts in my css (@font-face)

I'm trying to get these fonts and add them to my css: lato bold italic 24, lato regular 14, lato bold 14, lato light 14, lato light italic 16 I found these fonts in this site: http://www.fontsquirr..

1

answers

Uninitialized Constant MessagesController

I'm building a simple chat app based on this rails cast. I'm following along fine, but when I go to localhost, I get an error "uninitialized constant MessagesController::Message". This is generally a ..

1

answers

Adding a UISegmentedControl to UITableView

How do I add a UISegmentedControl to a UITableView? Similar to the image found here: http://cdn.imore.com/sites/imore.com/files/styles/large/public/field/image/2012/08/iHomework-for-iPhone-managing-as..

3

answers

How to implement a simple scenario the OO way

After starting to read a book on OO programming, I am attempting to make my android app more OO. However I am stumped on a simple scenario. I have a Book object, which can have many say Chapter objec..

1

answers

Embed ruby within URL : Middleman Blog

I am having some problem with some facebook share link on Middleman blog:- Well I have : <%= link_to current_article, article %> => <a href="http://0.0.0.0:4567/link_of_article">Artic..

2

answers

How to make a variable accessible outside a function?

I am fetching data from a json file using $.getJSON to get an id of a character and then use $.getJSON to fetch it from another page using the id that I go previously. However, in the console it says..

4

answers

Method Call Chaining; returning a pointer vs a reference?

I have a Text class that has certain methods that return a pointer to itself, allowing calls to be chained. (The reason being I merely like how the chaining looks and feels, honestly!) My question i..

1

answers

Jquery assiging class to th in a table

I am trying to assign class to table headers. I am trying to read class names of td's and assign it to related th header. Any help would be appreciated. <table > <tr> <th>hdr..

1

answers

How to use a global array in C#?

I am making an text-based adventure game for my first little project in C#. In order for my vision to work I need a few arrays that can be accessed in any of the functions. The game will only consist ..

3

answers

Two constructors

As I remember I can use first constuctor in second constuctor, but there is mistake on bold line, could you help me to correct it? public FaceExtAdditionCanvas() { profileImage.setSize(IMAGE_WI..

1

answers

Crop image to specified size and picture location

I have an image that is being taken using AVCaptureSession and being returned to my view controller. Here is a screen shot of the camera interface: The AVCaptureSession takes the FULL SCREEN phot..

1

answers

Is there a way to view two blocks of code from the same file simultaneously in Sublime Text?

Is there a way to view two blocks of code from the same file simultaneously in Sublime Text? I can't find anything in the view options...

5

answers

How do I get some variable from another class in Java?

I am "playing around" with Java, watching tutorials and trying to get the hang of it. For this question, I'm trying to figure out how I can take a variable from another class and use it in my main one..

1

answers

How can I tell if an algorithm is efficient?

Relatively new to C++ but I am very interested in the algorithmic aspect of programming. Is there a general framework for deciding if an algorithm is efficient? i.e. the quickest possible? I am tryi..

1

answers

Better solution without exluding fields from Binding

I have an entity Movie that has 2 fields(poster and trailer) of varbinary(max) within the database. When I want to create the instance on the controller I had a lot of problem trying to get those fiel..

2

answers

How to correctly write async method?

So I am trying to learn the basics of using 'async' and 'await' in C#, but I am not sure what I am doing wrong here. I am expecting the following output: Calling DoDownload DoDownload done [...output..

4

answers

this in equals method

I am looking at the equals method, and I see this and I don't understand what it means...I do understand them when I see it in constructors and some methods but its not clear to me when they are in eq..

1

answers

How to split a string in two and store it in a field

I have a class of fields that is like the following: public class EmployeeInformationNames { private String firstName; private String lastName; public String getFirstName() { re..

1

answers

Titlecase all entries into a form_for text field

Trying to title-case all the entries from a form_for field so they're consistent going into the database for searches. Here is my search field (file created as a partial): <%= form_for @airport ..

1

answers

Undefined Symbols error when integrating Apptentive iOS SDK via Cocoapods

When integrating the Apptentive iOS SDK via Cocoapods, I get the following errors: Undefined symbols for architecture i386: "_OBJC_CLASS_$_ATConnect", referenced from: objc-class-ref in AppDe..

1

answers

How to do perspective fixing?

I'm searching for a fast way to fix perspective of a picture given in java or any language.And currently i really don't have any idea how to do it, nor find anything useful in Google. Input: Point[4]..

2

answers

Ruby - ignore "exit" in code

Consider this code: class Bar def initialize puts 'Hi from class Bar.' exit end end class Foo def initialize loop { case $stdin.gets.chomp when 'foo' puts 'Hi ..

1

answers

String index out of range: 4

I am a beginner here to Java. So I tried to run this code here, but it kept giving me this error: Exception in thread "main" java.lang.StringIndexOutOfBoundsException: String index out of range: 4. ..

1

answers

Keep placeholder text in UITextField on input in IOS

Is there any way to prevent placeholder text in a UITextField from being overwritten when the text field receives an input? I have a text field that takes an expiration date in this format "MM/YYYY" w..

5

answers

python variable NameError

I am having trouble with assigning values to vars and then accessing the values. For example: # offer users choice for how large of a song list they want to create # in order to determine (roughly) h..

2

answers

Pass PDO prepared statement to variables

I am using a prepared statement to upload submitted information into a MYSQL database. I would like to know how to pass my prepared statements to a separate variable so I can post a summary of what wa..

3

answers

Why my regexp for hyphenated words doesn't work?

I'm writting a regular expression for match with simple words and single hyphenated words using re module of python, so for example in: test_case_input = """the wide-field infrared survey explorer is..

1

answers

AngularJs directive not updating another directive's scope

I have a parent directive that has a function that loads a modal div with data after a service call. I have confirmed that the service correctly returns data, but that data model is never passed to t..

1

answers

Where do I put a single filter that filters methods in two controllers in Rails

I have a single method I want to use as a filter in two controllers. Is there a central location I can place it or must I duplicate the code in both controllers?..

1

answers

My eclipse won't open, i download the bundle pack it keeps saying error log

Its say this huge message. Showing the last part , and I am on windows !ENTRY org.eclipse.osgi 4 0 2013-12-31 18:02:27.633 !MESSAGE Application error !STACK 1 java.lang.RuntimeException: Application..

2

answers

Passing multiple values for same variable in stored procedure

I have a variable that passes multiple values to stored procedure. When I see through fidler I see values being passed correctly like arg1=331 arg1=222 arg1=876 arg1=932 In my st..

2

answers

grep's at sign caught as whitespace

I ran into a problem while trying to grep a file that contains the following: @abc abc abc @[email protected] @[email protected] @[email protected] acb [email protected] assd dsasd [email protected] I tried various grep commands, but there was a problem an..

2

answers

Hide Signs that Meteor.js was Used

In order to design a blind test, how can a Meteor.js app hide signs that Meteor.js was used to build the site? PHP have a X-Powered-By header that can be removed, what hints do Meteor have?..

1

answers

Gradle - Move a folder from ABC to XYZ

Directory Structure: Project1/ABC/file1.txt I want the above ABC folder moved/renamed to XYZ (without leaving ABC there). How can I do this using Gradle. Seems like in Gradle: For a right hand pers..

2

answers

C# - insert values from file into two arrays

I want to read values from text file and insert them to 2 arrays, the first column to one array and the second column to another array. For example: Text file: 0x223 0x2342342 0x21323 0x9832..

1

answers

Implement specialization in ER diagram

I want to implement this specialization relationship. Knowing that I will have different attributes for each account type. Here's my try: accounts(account_id, email, username, password, ...) user_a..

1

answers

concat yesterdays date with a specific time

I need to create a query that looks at yesterdays date but at a specific time. I would like the time portion to be in the 'hh24:mi:ss' format as this is how the search field is formated. when I run ..

1

answers

Comparing a variable with a string python not working when redirecting from bash script

First I'll show you both the bash and python script (both are in the /bin directory on my mac): The bash script (esh_1): #! /bin/bash echo -n "Enter bash or natural-language command: " read INPUT e..

1

answers

getting " (1) no such column: _id10 " error

I'm trying to retrieve the data of a particulate row in a sqlite database . and trying to display it to on a EditText but I'm getting this error , Kindly help me in solving the error ! Thanks in adva..

1

answers

Accessing AppDelegate from framework?

I'm creating my first framework in Objective-C that wraps the facebook SDK in a more intuitive way. There are several points in my framework where I'd like to reference the AppDelegate, but there is n..

3

answers

Empty brackets '[]' appearing when using .where

I'm trying to display all Guides where title contains the word 'attack'. I do so like so: def attack @guides = Guide.where(title: 'attack') end Quick question - How do I make it non case-sensitiv..

1

answers

Xml Parsing in C#

http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/2.5_day.atom on this site, I wrote the following code to retrieve the data. protected void Button1_Click(object sender, EventArgs e) {..

3

answers

Instantiating a generic type

I'm trying to convert an existing class to use generics, and am getting stumped while converting the constructors. The original class was a POJO that contained logic for moving from one room to anoth..

1

answers

Does the target directory for a git clone have to match the repo name?

In other words, I have a repo up on Github called st3_packages (https://github.com/pitosalas/st3_packages). I want to do a git clone and have it create a directory on my local computer called "Pack..

5

answers

When to create variables (memory management)

You create a variable to store a value that you can refer to that variable in the future. I've heard that you must set a variable to 'null' once you're done using it so the garbage collector can get t..

1

answers

OS X Sprite Kit Game Optimal Default Window Size

I am looking to port an iOS Sprite Kit game to OS X. I'd like to provide the sharpest image quality possible. Since iOS device support only a handful of resolutions and I believe 3 aspect ratios this ..

1

answers

How to get parameter value for date/time column from empty MaskedTextBox

I'm having a problem adding a parameter of date/time type to my insert statement. For textual data you can leave the textbox empty and the record will be added but with date/time data I can't. I get t..

1

answers

How to create a showdown.js markdown extension

Using the following code, I get working output: <html> <head> <script type="text/javascript" src="/js/showdown.js"></script> </head> <body> <scrip..

3

answers

SQL permissions for roles

I'm a bit confused about permissions in SQL I have created a medical database. As a script I'm creating a doctor role and I want to say they can perform updates on tables 1,2 and 3. The database th..

2

answers

Difference between opening a file in binary vs text

I've done some stuff like: FILE* a = fopen("a.txt", "w"); const char* data = "abc123"; fwrite(data, 6, 1, a); fclose(a); and then in the generated text file, it says "abc123" just like expected. Bu..

1

answers

Parse error: syntax error, unexpected [

I have this simple function function render($template, $values = []) { // if template exists, render it if (file_exists("../templates/$template")) { // extract variables into l..

1

answers

Please help me convert this script to a simple image slider

Can some please, PLEASE! help me with this problem. Okay so I have a code that at first I thought worked well but I forgot that when the default <img src="test-img-1.jpg" class="actual-img"> con..

1

answers

java doesn't run if structure inside of onclick listener

All you must see as code is below. bSet.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { // TODO Auto-generated method..

1

answers

String method cannot be found in a main class method

I have about a one year experience programming Java, I made a static method located in the main class, and for some reason, whenever I compile it gives me an error saying that the compareTo() method f..

1

answers

Autoresize View When SubViews are Added

I am developing an app using iOS 7 and auto layout. I am adding a simple textfield to a UIView. But the view is not getting resized. I even tried to change the frame manually but it did not work. I be..

1

answers

Preg_match backtrack error

When I use the regex (.*)*[0] everything works well: preg_match('/(.*)*[0]/', 'this is a test string'); var_dump(preg_last_error()); // no code's returned But when I add another character to char c..

1

answers

Parameter binding on left joins with array in Laravel Query Builder

I trying to do a left join with where IN clause search. But I couldn't able to bind the array to the query. $query = DB::table('offers'); $query->select('id', 'business_id', 'address_id',..

1

answers

Setting default checkbox value in Objective-C?

Okay, this one's making me feel stupid... I'm a feature film editor who's recently started teaching myself Objective-C after many years away from coding. I think the last code I wrote was in Cobol, i..

1

answers

Highlight Anchor Links when user manually scrolls?

I apologize for the long post. I wanted to include everything that might be helpful. I have a single page website that consists of several divs stacked vertically. I'm using a floating nav bar and so..

2

answers

Intermediate language used in scalac?

In the GCC compiler we see several 'intermediate languages': RTL, GENERIC and GIMPLE. This answer hints at the idea of an intermediate representation in scalac. My question is: is there an 'interm..

2

answers

Generating a list of pages (not posts) without the index file

I am using Jekyll as a static generator for a website (not a blog), and I want to have an automatically generated list of all pages on my index page. I get that to work with the following code for the..

1

answers

Warp \ bend effect on a UIView?

I'm trying to get a similar effect to the one described in the pictures. The white area on the left isn't on the original photo, it pushes the pixels away. I've tried using Core Image (which offered a..

2

answers

Why there is this "clear" class before footer?

I have recently been modifying a template from Blogofile, which is written in HTML 5. When I looked at the generated page, there is this <div class="clear"></div> box in the html sourc..

1

answers

Generic XSLT Search and Replace template

I am trying to find (before re-inventing) a "simple" XSLT template that will take ANY xml document, find ALL text elements within that XML and replace all ' with ''. I'm doing a "SELECT ... FOR XML" ..

1

answers

Are all Spring Framework Java Configuration injection examples buggy?

I'm wondering if it's only me or are most examples of Spring's Java Configuration flawed? Like here for example: http://spring.io/blog/2008/03/27/spring-java-configuration-what-s-new-in-m3 http://sp..

1

answers

Calling another method java GUI

I'm trying to make a GUI, and I can accomplish it all in one method, but I would like to make the code simpler and make multiple methods. However, I can't get it to work. I am new to Java programming...

1

answers

Use NSInteger as array index

Have a happy year! I am having trouble with the following. First logic: Get json from server. Json value is always a number. Read plist into array. NSLog the array with index of the json value from ..

1

answers

I need to know how to get my program to output the word i typed in and also the new rearranged word using a 2D array

I have a working program which takes the first letter of a word then switches it to the back of the word and adds "ay to the end. It works fine but I am trying to store the original word and the newW..

1

answers

Summing radio input values

I'm new to this so I have been trying to adapt code from others to suit my needs, I need a radio selection from the first name group to be added to the second name group and then displayed in the text..

5

answers

Removing "http://" from a string

I have a PHP script that removes the "http://" from user input url strings. My Script: $url= "http://techcrunch.com/startups/"; $url = str_replace('http://', '', $url); Result: $url= techcrunch.c..

3

answers

Is it possible to change the content HTML5 alert messages?

Is it possible to control HTML5 alert messages? when adding 'required' to an input field. because I want it to be specific and I don't want it's language to depend on the browsers. <input id="ans..

2

answers

Java and unlimited decimal places?

Is there a simple way that i can manipulate high precision decimal numbers in java, without a limit on the number of decimal places, and the ability to output the number in a println or write it to a ..

1

answers

Zipping a file in bash fails

I have this line of code in a file called backup.sh, located in /backup (so the path is /backup/backup.sh) The code is: #!/bin/bash zip -r /backup/Backup-$(date +%Y-%m-%d) /ftb The file has permis..

3

answers

is it possible to add colors to python output?

so i made a small password strength tester for me, my friends and my family, as seen here: import re strength = ['You didnt type anything','Terrible','weak sause','avarage','Good!','Very Strong', 'TH..

1

answers

Read input from a JOptionPane.showInputDialog box

I am almost done with this project. It's my very first one and I need to read a little better the inputs from the JOption box. For example, I want to go back to the previous page if the user clicks on..

1

answers

Cannot retrieve string(s) from preferences (settings)

I have encountered a problem in my Android application. The problem is that for some reason, I can't retrieve the string of a ListPreference from my preferences.xml file. Here's the code I tried: p..