Posts by Raphael Prado de Oliveira • 1,472 points
102 posts
-
0
votes1
answer516
viewsA: Changing the Checkbox color via Styled-Components
I managed to solve as follows: setting the property tintColors of own CheckBox. <CheckBox disabled={false} value={isDoctor} onValueChange={setIsDoctor} tintColors={{ true: '#FC8F00' }} />…
-
0
votes1
answer516
viewsQ: Changing the Checkbox color via Styled-Components
I need to change the color of one CheckBox when it is selected. I am using it as follows: index.js import CheckBox from '@react-native-community/checkbox'; ... <CheckBoxes>…
-
0
votes1
answer14
viewsA: Error while capturing Tinyurl shorten method
Implement as follows: const shortUrl = await TinyUrl.shorten(req.body.url); // Tudo certo para CRIAR o Site const { id, hits, url, short_url } = await Site.create({ hits: 0, url: req.body.url,…
-
0
votes1
answer14
viewsQ: Error while capturing Tinyurl shorten method
I need to capture the return of the method shorten library TinyUrl. I’m trying to store this return in the variable shortUrl and then save to the bank as follows: import TinyUrl from 'tinyurl'; let…
-
1
votes1
answer62
viewsQ: Error sending email with Sendgrid in Nodejs
I have the following structure to send emails by SendGrid: import mail from '@sendgrid/mail'; function send(email_data) { mail.setApiKey(process.env.SENDGRID_API_KEY); const message = { to:…
-
1
votes1
answer55
viewsA: Field multiplication in Sequelize
I solved it as follows. I used the literal of Sequelize: import { literal } from 'sequelize'; const buys = await Buy.findAll({ where: { account_id: req.params.id, }, attributes: [ 'id',…
-
0
votes1
answer55
viewsQ: Field multiplication in Sequelize
I have the following code thingy: const buys = await Buy.findAll({ where: { account_id: req.params.id, }, attributes: ['id', 'account_id', 'buy_value', 'quantity'], }); return res.json(buys); That…
-
0
votes2
answers176
viewsQ: Datepicker component breaking the screen in editing
I created the following component to select dates in Unform: export default function DatePickerInput({ name, ...rest }) { const datepickerRef = useRef(null); const { fieldName, defaultValue = '',…
-
0
votes1
answer570
viewsA: Group By with Sequelize
I decided as follows: async index(req, res) { // Recebendo os Query Parameters const { page = 1 } = req.query; const champions = await Champion.findAll({ limit: 5, offset: (page - 1) * 5, order:…
-
-2
votes1
answer570
viewsQ: Group By with Sequelize
I have the following class structure: I’m trying to group and count Sequelize how many titles each selection had from the table Cup_Selections same as the query typed below: My Node consultation…
-
1
votes1
answer516
viewsQ: Right alignment with Styled Components
I need to align the yellow content to the right of my menu bar as follows: But when trying, align, the content is glued to the menus: The layout of my elements and my CSS are as follows: return (…
-
1
votes1
answer136
viewsA: Model filter tied by Sequelize
Solved as follows, using the Sequelize Op: const Sequelize = require('sequelize') const Op = Sequelize.Op ... // Filter all Deliveries with problem const ids = [...new Set(response.map((x) =>…
-
-2
votes1
answer136
viewsQ: Model filter tied by Sequelize
I have two models in my application, Delivery and Deliveryproblem. Deliveryproblem has a PK (delivery_id) of Delivery: static associate(models) { this.belongsTo(models.Delivery, { foreignKey:…
-
1
votes1
answer166
viewsA: Error finding directory . handlebars
I found the problem. The property extname from within the method create, is written all lower case. Only property extName of the method use is written in capital letters N. configureTemplates() {…
-
1
votes1
answer166
viewsQ: Error finding directory . handlebars
I have the following folder and file structure in my Node project: And the following configuration of email templates: configureTemplates() { const viewPath = resolve(__dirname, '..', 'app',…
-
0
votes2
answers210
viewsA: Error opening Android React-Native project on Androidstudio via macos
I found that the command react-native init exercícios was not creating the project properly. I needed to change the read and write permissions in the project folder to be able to work properly. I…
-
1
votes2
answers210
viewsQ: Error opening Android React-Native project on Androidstudio via macos
I’m trying to open a project Android React-Native existing through the AndroidStudio, but the following exceptions are displayed for me:…
-
1
votes1
answer197
viewsA: Error executing React-Native init command
The permission error in the folder has been fixed with the command sudo before the command react-native, with the complete command as follows: > sudo react-native init exercicios…
-
0
votes1
answer197
viewsQ: Error executing React-Native init command
I’m trying to create a project React Native in the MacOs for Terminal. I type the following commands in Terminal: > cd Desktop > mkdir curso-react > cd curso-react/ > react-native init…
-
0
votes1
answer48
viewsA: Error installing HAXM on Mac OS X
I was able to install HAXM manually by downloading the following link: https://github.com/intel/haxm/releases/tag/v7.5.1…
-
0
votes1
answer48
viewsQ: Error installing HAXM on Mac OS X
Good morning. I’m new to Mac and I’m having a hard time installing Android Studio in the Operating System. The following error is displayed to me in the installation of HAXM: I read in some places…
-
2
votes1
answer841
viewsA: Converting Boolean to YES or NO to Angularjs
I found the following link :Angularjs-print-yes-or-no-based-on-Boolean-value and I resolved it as follows: <td>{{true == p.IsAtivo ? 'Sim' : 'Não' }}</td>…
-
2
votes1
answer841
viewsQ: Converting Boolean to YES or NO to Angularjs
I have the following table structure in my form HTML: <tbody> <tr nr-repeat="p in model.previdencias"> <td>{{p.NomeDependente}}</td> <td>{{p.IsAtivo}}</td>…
-
1
votes1
answer610
viewsQ: Aligning images within Bootstrap Panel
I got the following Panel: <div class="panel panel-primary"> <div class="panel-heading"> <h3 class="panel-title">Header</h3> </div> <div class="panel-body">…
-
2
votes1
answer3740
viewsQ: Camera permission on Android
I have the following permission to access the camera and store the Androidmanifest.xml file: <uses-permission android:name="android.permission.CAMERA"/> <uses-permission…
-
2
votes1
answer56
viewsQ: Organizing app photos into folder
I have the following code snippet to define the description of the photos my app will take and where the photos will be saved. private File criarArquivo() throws IOException { String descricao = new…
-
0
votes0
answers77
viewsQ: Error while running Android application with Opencv
I am trying to open my application on my Smartphone (Motorola G4 Play), but I am not successful. The following error is shown to me: E/art: No implementation found for void…
-
2
votes1
answer4466
viewsQ: Ignoring files by . gitignore
Use the GitLab as a repository for a project Android. I want to ignore the files from the folder openCVLibrary320 at the time of commit/push. I typed the folder as follows in the file .gitignore:…
-
0
votes3
answers341
viewsA: Setting Focus() in Usercontrol Textbox
I had to do it this way: I created the method setFocus() in my UserControl which arrow the Focus on the desired component. public partial class SliderChrome : UserControl { private int _min; public…
-
1
votes3
answers341
viewsQ: Setting Focus() in Usercontrol Textbox
I have the following Usercontrol : public partial class SliderChrome : UserControl { private int _min; public int Min { get { return _min; } set { txtmin.Text = _min.ToString(); } } } I use this…
-
1
votes0
answers80
viewsQ: Java SOAP Web Service error in Glassfish
I have the following method in a SOAP Web Service running through Glassfish 4.1.1: @WebService(serviceName = "CalculatorWS") @Stateless() public class CalculatorWS { @WebMethod(operationName =…
-
0
votes1
answer341
viewsA: Error running Java Webservice
Solved. I had to Deploy the Web Service. I did it this way: I right-clicked on the Project and clicked on Deploy, as follows the image:…
-
0
votes1
answer341
viewsQ: Error running Java Webservice
I’m trying to run a Web Service SOAP by the server GlassFish Server 4.1.1 in the NetBeans 8.2. When trying to execute the following error is returned: Methods of Web Service: @WebService(serviceName…
-
0
votes1
answer1206
viewsA: Error when cloning Gitlab repositories
Solved. In Gitlab, I set a password for HTTPS. By cloning the repository, I just used that password to authenticate.
-
0
votes1
answer1206
viewsQ: Error when cloning Gitlab repositories
I am trying to clone a repository I have created in Gitlab on my machine, but the following error is returned to me : I used the Github login to log into Gitlab and create the repository there. When…
-
0
votes6
answers615
viewsA: Regular Expressions with Java Patterns
Solved. I used the following Pattern: Pattern pattern = Pattern.compile("(bbb*ab*ab*)|(babb*ab*)|(baabb*)|(ababb*)|(aabbb*)|(abbb*ab*)");
-
2
votes6
answers615
viewsQ: Regular Expressions with Java Patterns
I need to do a college exercise, which is this: Validate with regular expressions any word that contains exactly two characters 'a' and two characters 'b' or more. I made the following expression in…
-
1
votes0
answers182
viewsQ: Problems to compile in Android Studio
I created my first Project in Android Studio defining as Minimums SKD the API 23 Android 6.0 (Marshmallow). Then I created a virtual device in AVD Manager with the following settings: Nexus 5 API 24…
-
6
votes2
answers644
viewsQ: Arc tangent function in C#
I did the following calculation on the calculator: arctg(50/10) = 78,69° However, when doing in the code, using the function Math.Atan, the result is as follows: Is there any other way to calculate…
-
1
votes1
answer400
viewsQ: E-mail Phpmailer to Hotmail
I am not able to send an email form to my e-mail Hotmail. Below follow the codes: Form with the data that will be sent. <form id="form-contato" method="post" action="email.php"> <div>…
-
0
votes1
answer45
viewsQ: E-mail using the Phpmailer class
I got the following form on my page index.php : <form id="form-contato" method="post" action="email.php"> <div> <div class="row"> <div class="6u 12u(mobile)"> <input…
-
5
votes1
answer6305
viewsA: Centralizing modal bootstrap
Solved. I changed the CSS code with the contents below: .modal { text-align: center; padding: 0!important; } .modal:before { content: ''; display: inline-block; height: 100%; vertical-align: middle;…
-
3
votes1
answer1257
viewsA: Centralizing modal bootstrap on mobile screen
Solved. I changed the CSS code with the contents below: .modal { text-align: center; padding: 0!important; } .modal:before { content: ''; display: inline-block; height: 100%; vertical-align: middle;…
-
2
votes1
answer1257
viewsQ: Centralizing modal bootstrap on mobile screen
I’m trying to centralize a modal bootstrap in the center of a mobile screen, but the result is the following: I’m following this example, but it’s not working: How to Center a Modal Box Horizontally…
-
2
votes1
answer6305
viewsQ: Centralizing modal bootstrap
I have a modal bootstrap on my page HTML. When I open the modal in the computer browser, the modal appears as follows: But when simulating the screen of a smartphone, the modal behind my menu nav:…
-
4
votes2
answers7812
viewsQ: Accessing Components from Another Form
I have two Forms in my application. A Form for data from an engine that has the following fields: txtPotencia, txtTensao and txtCorrente. I would like to access the values filled in these TextBox…
-
0
votes0
answers147
viewsQ: X-axis time of graphics C#
I have the following chart in my Windows Form: I set the X axis to display Time, as shown below: Below the methods I call to draw the graph: private void funcaoQualquer() { while (true) {…
-
1
votes2
answers181
viewsQ: Links in strip menu
You can link to a site in the Strip Menu of Windows Forms? I have the following code snippet in the click of my menu, but does not open the link. private void menuSobre_Click(object sender,…
-
1
votes1
answer7683
viewsQ: Bootstrap modal does not open
I have a button that when clicked opens a modal of bootstrap. However, when clicking this button, the modal is not opening. It follows the structure of the code: <html> <head> <script…
-
2
votes2
answers477
viewsQ: Validation of Textbox
I have the following piece of code that limits a TextBox receivable only numbers and comma: private void txtTempoAcel1_KeyPress(object sender, KeyPressEventArgs e) { if (!Char.IsDigit(e.KeyChar)…