SyntaxFix.com - Programming Questions & Answers Hub For Beginners

Some Of The Best Answers From Latest Asked Questions

Unable to allocate array with shape and data type

I'm facing an issue with allocating huge arrays in numpy on Ubuntu 18 while not facing the same issue on MacOS. I am trying to allocate memory for a numpy array with shape (156816, 36, 53806) with np.zeros((156816, 36, 53806), dtype='uint8') and...

How to fix error "ERROR: Command errored out with exit status 1: python." when trying to install django-heroku using pip

I am trying to install django-heroku using pip, but it keeps running into an error. I have seen suggestions telling me to make sure my Python version in Heroku is up to date. I have already done that. After pushing to Heroku master, I ran the install...

How to prevent Google Colab from disconnecting?

Q: Is there any way to programmatically prevent Google Colab from disconnecting on a timeout? The following describes the conditions causing a notebook to automatically disconnect: Google Colab notebooks have an idle timeout of 90 minutes and ...

Element implicitly has an 'any' type because expression of type 'string' can't be used to index

Trying out TypeScript for a React project and I'm stuck on this error: Element implicitly has an 'any' type because expression of type 'string' can't be used to index type '{ train_1: boolean; train_2: boolean; train_3: boolean; train_4: boolean; }'...

dotnet ef not found in .NET Core 3

I'm following the docs in order to create an initial migration. When I execute dotnet, I get the help section, meaning that the PATH works properly. Then I try to execute the command below from the docs in console window: dotnet ef migrations add I...

"Permission Denied" trying to run Python on Windows 10

Seems as though an update on Windows 10 overnight broke Python. Just trying to run python --version returned a "Permission Denied" error. None of the three updates; KB4507453, KB4506991, or KB4509096 look like they'd be the culprit but the timing of...

Adding Git-Bash to the new Windows Terminal

I'm trying to add a new terminal (Git Bash) to the new Windows Terminal, however I can't get it to work. I tried changing the commandline property in the profiles array to git-bash.exe but no luck. Does anyone have an idea how to get this to work?...

Angular @ViewChild() error: Expected 2 arguments, but got 1

When trying ViewChild I am getting the error. Error is "An argument for 'opts' was not provided." Both @ViewChild is giving the error. import { Component, OnInit, ElementRef, ViewChild, Output, EventEmitter } from '@angular/core'; import { Ingredie...

Invalid hook call. Hooks can only be called inside of the body of a function component

I am new to React and Now I would like to show some record in the table and now I got this error. Help me, please. Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the followin...

"UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure." when plotting figure with pyplot on Pycharm

I am trying to plot a simple graph using pyplot, e.g.: import matplotlib.pyplot as plt plt.plot([1,2,3],[5,7,4]) plt.show() but the figure does not appear and I get the following message: UserWarning: Matplotlib is currently using agg, which is a...

Typescript: No index signature with a parameter of type 'string' was found on type '{ "A": string; }

I have some vanilla javascript code that takes a string input, splits the string into characters, and then matches those characters to a key on an object. DNATranscriber = { "G":"C", "C": "G", "T": "A", "A": "U" } function toRna(sequ...

Schema validation failed with the following errors: Data path ".builders['app-shell']" should have required property 'class'

Schema validation failed with the following errors: Data path ".builders['app-shell']" should have required property 'class'. Schema validation failed with the following errors: Data path ".builders['app-shell']" should have required property 'c...

Is it possible to opt-out of dark mode on iOS 13?

A large part of my app consists of web views to provide functionality not yet available through native implementations. The web team has no plans to implement a dark theme for the website. As such, my app will look a bit half/half with Dark Mode supp...

Make a VStack fill the width of the screen in SwiftUI

Given this code : import SwiftUI struct ContentView : View { var body: some View { VStack(alignment: .leading) { Text("Title") .font(.title) Text("Content") .lineLimit(nil) ...

Access blocked by CORS policy: Response to preflight request doesn't pass access control check

I'm trying to create a user administration API for my web app. When I send an API call from my frontend to my backend, a cors error occurs. How can the cors problem be solved? I've read a lot of threads, but I haven't made any progress. Error after ...

SwiftUI - How do I change the background color of a View?

I'm beginning to try out SwiftUI and I'm surprised that it doesn't seem to be straightforward to change the background color of a View. How do you do this using SwiftUI?...

Presenting modal in iOS 13 fullscreen

In iOS 13 there is a new behaviour for modal view controller when being presented. Now it's not fullscreen by default and when I try to slide down, the app just dismiss the View Controller automatically. How can I prevent this behaviour and get bac...

How to style components using makeStyles and still have lifecycle methods in Material UI?

I get the below error whenever I try to use makeStyles() with a component with lifecycle methods: Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons: ...

Errors: Data path ".builders['app-shell']" should have required property 'class'

I am getting this error while running my application. Here are the details of my application. Angular CLI: 7.3.3 Node: 10.15.1 Angular: 7.2.7 @angular-devkit/architect -0.13.3 @angular-devkit/build-angular- 0.800.1 @angular-devkit/build-optimi...

DevTools failed to load SourceMap: Could not load content for chrome-extension

I'm trying to display an image selected from the local machine and I need the location of that image for a javascript function. I have recently started learning javascript. I am facing this error and unable to get the location of the image. For getti...

When adding a Javascript library, Chrome complains about a missing source map, why?

My code <html> <head> <!-- Load TensorFlow.js --> <script src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs"></script> <!-- Load Posenet --> <script src="https://cdn.jsdelivr.net/npm/@tensor...

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: Message: session not created: This version of Chr...

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 been pointed to, following other answers. The only t...

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 string. Received type undefined I have no idea w...

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 issues but I couldn't fix it. Here's the full error ...

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 with typescript Errors looks like this: ERROR i...

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] Could not load dynamic library 'cudart64_101.dll'; d...

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 other things but nothing seems to fix it. My next ...

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 Obj-C and/or Swift as well. I have pulled the new...

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 function register(Request $request) { dd('aa...

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 component: App.js import './App.scss' function Ap...

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-12-11T21:09:53.441+05:30 [APP/PROC/WEB/0] [ERR] df1...

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 find build in loglik function nor AIC Shall I use ...

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/fulldisclosure/ for any of the products we use. This is a slo...

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 looking at the run configuration and writing the ...

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 appreciated....

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. I have also tried calling it from a different obje...

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 - headers already sent (output started at /customer...

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) { mGraph.put(node, new HashMap<T, Double>()); ...

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="hidden" name="fk_id[]" value="<?php echo $veh...

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 should change the angle depending on each value. We...

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> <input type="radio" name="color1" id="red" />&a...

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 <stdio.h> #include <stdlib.h> main() { ...

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" would exactly be. Thanks for your help!...

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. Unfortunately this has multiple references to the same DL...

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.fontsquirrel.com/fonts/lato I downloaded it. there are some...

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 simple fix, but I have spent over an hour looking ...

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-assignments-and-tasks.jpg I would like to have a UI...

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 objects. I also have a search function which searches a...

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">Article Title</a> I am trying to have:- <a c...

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 https://prod.api.pvp.net/api/lol/eune/v1.2/s...

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 is, which is generally better in practice (in terms...

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>hdrcol1</th> <th>hdrcol2</th> ...

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 of a single class. And the arrays will need to be ...

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_WIDTH, IMAGE_HEIGHT); add(profileImage, getWidth...

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 photo, and now I want to crop it down to the size of t...

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....

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, without making the initial variable public. Here...

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 trying to write pseudocode on paper before implementin...

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 fields from the View, finally, I got this solution: [...

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 here...] But I don't get the output of the down...

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 equals method something like this: (obj == this) .....

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() { return firstName; } public void setFirstName...

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 do |f| %> Input city <%= f.text_field :c...

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 AppDelegate.o "_OBJC_CLASS_$_ATAppRatingFlow", refere...

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] , Color[][] Output: Perspective-Fixed Color[][] ...

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 from class Foo.' when 'bar' Bar.new ...

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. I need some help. Here is my code: import java.u...

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" with placeholder text that reads "MM/YYYY" and I wa...

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) how many songs to copy print "\nHow much space shou...

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 was uploaded. Here is the following code: $stmt = $...

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 a nasa infrared-wavelength space telescope in an ...

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 the child directive's scope through the template. ...

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?...

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 "org.eclipse.ui.ide.workbench" could not be found...

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 stored procedure I am reading as procedure main...

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 @abc@ @abc@ @abc@ acb abc@ assd dsasd abc@ I tried various grep commands, but there was a problem and abc@ or @abc were caught as whitespace in my reg...

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?...

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 person, it's itching your right ear using your left ha...

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 0x983298 0x908938 0x8382AA arr1 : 0x223, 0x21323 , 0...

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_accounts(account_id, ..) admin_accounts(account_id,...

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 this query it works: where date_dt = to_date('201...

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 echo $INPUT > ~/USER_INPUT.txt $INPUT if (( $? )...

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 advance :) here is the logcat data showing error ...

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 no appdelegate when you create a static Cocoa Touch...

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-sensitive and restrictive? It can contain any spelling of ...

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) { string adresal = "http://" + txtAd.Text; ...

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 another in a text-based console game. Literally, it was...

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 "Packages". Is that possible?...

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 to it (if it's a field var). If I were to have a v...

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 is done fairly easily by providing different sprit...

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 the following error: Data type mismatch in crit...

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> <script type="text/javascript"> var converter =...

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 though actually contains 5 tables. does it mean tha...

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. But then I do: //this time it is "wb" not just "w" ...

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 local scope extract($values); // r...

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"> content is loaded the first of the three buttons belo...

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 stub String first = etFirstNumber...

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 from the String class can't be found. Here's the m...

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 believe it is because I am using auto layout. Here i...