Posts by Ulysses Alves • 2,165 points
86 posts
-
1
votes3
answers1344
viewsA: ERROR: No Resource found that Matches the Given name: attr 'colorAccent'
As suggested by Abdirahman, I solved this problem by deleting the entire contents of the folder C: Users USUARIO Appdata Local Xamarin and then cleaning and recompiling the solution again in Visual…
-
5
votes3
answers61753
viewsA: Remove a specific element from the javascript array
As I explain in my video about How to Remove Vector Elements in Javascript and also as other users already answered, basically you can use the function Array.splice(indice, quantidade) passing as…
javascriptanswered Ulysses Alves 2,165 -
1
votes2
answers36
viewsA: Checking for equalities between objects
You can iterate all fields of the first object and check if the value of these fields matches at the same value as the field in the second object. function compareObjetos(objA, objB) { if (objA ==…
-
0
votes2
answers6076
viewsA: How do I set up Visual Studio Code to open the console in a new window?
I finally figured out how to open the console in a window external to Visual Studio Code. According to the Visual Studio Code debugging documentation, just add, in the file Launch.json, the entrance…
-
5
votes1
answer1804
viewsA: Select taking the difference between Sqlite dates
This won’t exactly format your message the way you want it, but it can help you get the values separately and then concatenate them into a string and then assemble the final message. According to…
-
1
votes2
answers813
viewsA: How to prevent the page from opening outside an iframe?
Use the code below to check that the window in which the page was loaded is the browser window itself and not an iframe: if(window==window.top) { // Página não está em iframe, portanto lança um…
-
0
votes1
answer331
viewsQ: How to import mailing list from Hotmail/Outlook?
Recently I had to import the Hotmail/Outlook mailing list of the users of my application, and I present below one of the ways you can proceed if you also need to implement this feature in your…
-
0
votes1
answer331
viewsA: How to import mailing list from Hotmail/Outlook?
Step 1. Create a Windows Live app in the "Microsoft Account Developer Center" to get your Client ID and Client Secret Go to the page Microsoft Account Developer Center and create a new application…
-
8
votes2
answers6076
viewsQ: How do I set up Visual Studio Code to open the console in a new window?
In previous versions of the Visual Studio Code was opened in a window outside the Visual Studio Code, but in the new versions this screen of Console started to be opened inside the Visual Studio…
-
1
votes4
answers750
viewsA: How to limit the resources used by the system?
I worked on a Human Resources Budget system that processed the payroll budget of over 500,000 employees, with several calculation steps that really consumed a lot of operating system resources. The…
-
1
votes2
answers2019
viewsA: Error while running project in Visual Studio 2015
The mistake is why the file path is too long. Move the project to a less rooted folder in your directory structure. For example, C:/Projetos/SeuProjeto. This way you greatly reduce the probability…
-
0
votes8
answers67841
viewsA: How to export an HTML/PHP page to PDF
Use the library jsPDF. Runs on the client side without the need for any server processing. That doesn’t mean you don’t need a server, of course, but it makes jsPDF compatible with any server-side…
-
0
votes4
answers17125
viewsA: net error::ERR_BLOCKED_BY_CLIENT when making Ajax request
To extension of Avast blocks some analysis scripts (Google Analytics, for example) and social networks. Just add the domains of the blocked scripts as an exception in the settings of the Avast…
-
0
votes2
answers154
viewsA: Applying UX concepts to mobile development
UX is an English term meaning "User Experience", and is related to usability and graphical interface. It is a more up-to-date term for GUI (Graphical User Interface), the GUI being just the…
-
3
votes1
answer146
viewsQ: How to format money with jade in Node.js?
I have to present monetary values in my view, but it is appearing without formatting. For example, 5.4237 should be presented as R$ 5,42, but I don’t know how to format this value using the Jade…
-
6
votes3
answers97159
viewsA: How do I delete a local and remote Git branch(branch)?
To remove local branch: git branch -d nome-do-branch And to remove remote branch add the "-r flag": git branch -dr origin/nome-do-branch…
-
7
votes1
answer353
viewsA: What to do when Avast detects a threat in a harmless app?
Some anti-virus programs consider that an application is a potential threat when the developer does not sign the application with a digital key. Try adding a key to your project and make sure the…
visual-studioanswered Ulysses Alves 2,165 -
4
votes1
answer1056
viewsQ: Ajax POST with jQuery and Node.js Express always returning 404: Not Found
I created the route below to accept POST requests, but calls via AJAX to this route are always returning error 404: Not Found. /* Arquivo: integracoes.js */ var express = require('express'); var…
-
3
votes2
answers4319
viewsA: javascript Alert - disable "Block confirmation windows of this page?"
You can combine Javascript, HTML, and CSS to show much more beautiful and sophisticated alerts (e.g., modal windows) than alert browser default. The browser has no control over these custom alerts…
javascriptanswered Ulysses Alves 2,165 -
2
votes1
answer88
viewsA: Section does not work properly
From what I understand, all you had to do was add more elements li within the tag ul. ul li { list-style-type: none; } .imagem { background-image:…
-
1
votes1
answer135
viewsA: filter jQuery.getJSON results
The error is why some of the JSON records do not have the field you are trying to access. To avoid the error just check first if the field exists before trying to read the data: if (data.mus != null…
-
1
votes1
answer316
viewsA: How to create database apps in phonegap?
According to the Phone Gap data storage API documentation you have the following options to locally persist your application data: Localstorage Websql Indexeddb Plugins…
apache-cordovaanswered Ulysses Alves 2,165 -
1
votes2
answers715
viewsA: Add the 5 highest values to an array
One way is to first sort the vector in descending order, and then just take the first five elements of the vector. // Declara um vetor temporário do mesmo tamanho que a lista. Float[] temp = new…
-
1
votes1
answer388
viewsA: How do I leave absolute scroll to the div?
First you have to set a fixed height for the content area. Utilize overflow: auto for the area you want to have the vertical scroll bar. Utilize overflow: hidden and position: absolute for the left…
-
2
votes1
answer1072
viewsA: API with Javascript
One way and make an API is to create a separate Javascript file containing one or more objects declaring the functions you need in your API. For example, below is a dummy API representing a simple…
-
1
votes2
answers280
viewsA: Help with Textbox / string parameters
To change the value in the parameter IBGE is visible in the code that called the method you must define this parameter as out. Simply change the method signature to public bool recuperarIBGE(string…
-
0
votes4
answers847
viewsA: How to generate indented code?
To attempt texts within a string you can use the combination of escape characters \t, which will add a tab for each group of \t. It’s the same effect as typing the TAB key on the keyboard. To add…
-
1
votes3
answers3151
viewsA: How to read a Json file
To read a JSON file with Javascript you can use the function jQuery.getJSON: $.getJSON( "caminho_do_arquivo/arquivo.json", function( data ) { // processe os dados aqui }); The complete documentation…
-
2
votes2
answers1891
viewsA: json search with ajax in specific field
You can use a simple loop instead of using the $.each: for (var i = 0; i < json.length; i++) { $("#results").append("<div>" + json[i].Title + "<br><br></div>");…
-
0
votes1
answer124
viewsA: How to do an Xpath expression in an XML with multiple namespaces?
You can use the function local-name xpath: /*[local-name() = 'checkCredit']/*[local-name() = 'CheckCreditOut']/*[local-name() = 'addresses']/*[local-name() = 'decision']…
-
0
votes1
answer204
viewsA: Make a SQL Server process by receiving a special character string and getting only the numbers
First create a function to split your string into separate values: CREATE FUNCTION dbo.splitstring ( @separador CHAR, @stringToSplit VARCHAR(MAX) ) RETURNS @returnList TABLE ([Name] [nvarchar]…
-
2
votes1
answer75
viewsA: How to migrate my website to Requirejs?
Use the Requirejs Optimizer. You will also need the r. js, which is the tool that lets you run Requirejs from within Node.js. To generate a single file main.js containing all your Javascript files…
-
0
votes2
answers326
viewsA: Problem with margin-left in Internet Explorer
You need to put the statement !DOCTYPE in the first line of your page: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">…
cssanswered Ulysses Alves 2,165 -
1
votes2
answers544
viewsA: Progress bar on file upload and information registration
What you need is to add an overlay (gif) while your form is being sent, and hide that overlay when page loading is completed. $(document).ready(function() { $("body").prepend('<div id="overlay"…
-
0
votes2
answers79
viewsA: Reusing string in XML
To copy the value of one element into another you need to use XSLT and use the declaration <xsl:copy-of select="$NOME_DO_ELEMENTO_COPIADO" />. The example you set would look like this:…
-
1
votes2
answers174
viewsA: Problem with Sqlite Android Data Base
As far as I can tell, response of Sachin Garg for a similar question in English can solve your problem too: It looks like you added some columns later in the database. You should consider…
-
0
votes2
answers63
viewsA: HTACCESS - External File
Add in your . htaccess the entry below to allow access to the file arquivoPermitido.php Order deny,allow Deny from all <Files "arquivoPermitido.php"> Allow from all </Files>…
htaccessanswered Ulysses Alves 2,165 -
2
votes3
answers1370
viewsA: One button code to undo an action in C#
I suggest you make two changes to your code. The first change is to create a method to be called in the event click the numeric buttons, which will greatly remove the duplicity of your code. In…
c#answered Ulysses Alves 2,165 -
1
votes2
answers59
viewsA: Modal window does not work correctly by clicking YES
If your intention was to assign the click event to the element #yes child of the element #modalLogout then the change that must be made in your code is as follows: function time() {…
jqueryanswered Ulysses Alves 2,165 -
1
votes1
answer1422
viewsA: Overlay a static image with the webcam image
One option is to use the plugin jQuery Webcam to capture the image, assigning it as the source of an element img of your page in the method (or event) onSave. Your code would follow more or less the…
-
4
votes2
answers632
viewsA: Set model property in javascript variable
Place the model value in a hidden field (input type="hidden") and then assign the value of this hidden field in the Javascript variable. Razor code: <input type="hidden" id="codigo"…
-
1
votes3
answers5503
viewsA: Disable Function . click on DIV
You can disable mouse events on the elements by changing the attribute pointer-events of the element’s CSS style. In your specific case, at the beginning of your method you should run the code below…
-
2
votes1
answer1095
viewsA: Get list of applications installed on your computer
You can get the list of installed programs by reading the registry entries SOFTWARE Microsoft Windows Currentversion Uninstall windows, as follows: string registry_key =…
c#answered Ulysses Alves 2,165 -
2
votes1
answer1272
viewsA: How to change the name of the target database when performing the restore? (Restore C# .net class)
According to that answer in Stackoverflow in English, you should do the following: Assign the desired new name to the bank in the Property Restore.Database. Assign true value to Property…
-
0
votes2
answers91
viewsA: Debugging error in Visualstudio 2013
Apparently, the only solution to this error is to reinstall Visual Studio, according to that answer to the same question in English.…
-
1
votes1
answer573
viewsA: How to order a Listbox
You can sort the list with Linq and then assign the sorted list as Listview source data again. It would be something like this: private void btnOrdenaListView_Click(object sender, EventArgs e) { //…
c#answered Ulysses Alves 2,165 -
0
votes2
answers427
viewsA: print table from a defined size array
Use two ties for. The first for will be for the iteration of the lines, and the second for, internal to the first, will iterate the columns. $(document).ready(function(){ // De acordo com a…
javascriptanswered Ulysses Alves 2,165 -
0
votes1
answer56
viewsA: Auto adjustable list in shampoo
Use in XAML a Uniformgrid and enter the amount of columns you want (in this case they are 3 columns) in the field Columns. <UniformGrid Name="gridImagens" Columns="3"> </UniformGrid> Now…
-
2
votes2
answers2303
viewsA: How to modify the HTML document via an extension?
Chrome extension Create an empty directory which will contain the extension files. Create the manifest.json file in this directory. Add to the directory a Javascript file containing the code that…
-
2
votes3
answers1130
viewsA: Webbrowser - Click on elements of a website
You can get the element by the class and click on it without the need to iterate all page elements. webBrowser1.FindElementByClassName("preferred-login facebook-login").Click(); Or using the…