Posts by Lucas Kauer • 717 points
24 posts
-
1
votes2
answers634
viewsA: How to read a JSON using JAVASCRIPT ONLY?
The read of a disk file is asynchronous, so it is necessary to inform a callback function. function lerArquivo(arquivo, callback) { var rawFile = new XMLHttpRequest();…
-
0
votes4
answers173
viewsA: Error 404 Spring boot Ubuntu
You may not have permission in your directory. If you do not have it, try running the following command: sudo chmod +x "seu diretorio" Updated Also try to access as follows in Firefox: 0.0.0.0:80…
-
1
votes1
answer601
viewsA: Cannot implicitly Convert type list to an Object
The error is happening because it fails to convert the list of ... Days you return to the object ... Diassearch. Updated Replace the wrong line with: pont.result =…
-
2
votes1
answer89
viewsA: Is it possible to change values on the screen and send to the server?
If your doubt is more conceptual, the answer will be yes, the user can change the price values of the orders and/or products and/or the total in HTML. Therefore, it is recommended to always do the…
-
2
votes2
answers629
viewsA: Multiple Access-Control-Allow-Origin domains
Try this: <FilesMatch "\.json$"> <IfModule mod_headers.c> SetEnvIf Origin "http(s)?://(www\.)?(dominio.com|m.dominio.com)$" AccessControlAllowOrigin=$0 Header add…
-
0
votes4
answers111
viewsA: Get content between tags [x] and [/x] with Regular Expression
Try this regex (?<=\[\w{2}\-\w{2}\])(\.*)(?=\[\/\w{2}\-\w{2}\]).
-
1
votes1
answer526
viewsA: Add bar at end of URL with Htaccess
Try with that regex ^([A-Za-z-]+)\\\.htm$. \\ to verify \ literal (case sensitive) and \. to verify . literal (case sensitive)…
-
5
votes1
answer203
viewsQ: What are the differences between local functions, delegates and English expressions?
Local functions will be present in C# 7. Given this, I would like to know the main differences between local functions, delegates and expressions Amble.
-
0
votes2
answers56
viewsA: Problem . htaccess for www-free addressing
Try adding the flag L to stop processing the other rules. This means that if the rule matches, no other rule will be processed. The command corresponds to last in Perl or break in C. Use this flag…
-
0
votes1
answer68
viewsA: Query with Parameter causing timeout
Try to use SqlDbType.DateTime instead of DbType.DateTime. var dataInicioparameter = new SqlParameter("@dataInicio", SqlDbType.DateTime) { Value = dataInicio; };…
-
3
votes0
answers57
viewsQ: What are the disadvantages of immutable objects?
It is notorious the advantages of immutable objects, such as: they are more reliable because they are never changed; they are thread-safe, as they have no problems with synchronization when several…
-
16
votes3
answers572
viewsA: What is a devops?
Of the AWS Article (https://aws.amazon.com/pt/devops/): Devops is a combination of cultural philosophies, practices, and tools that increase an enterprise’s ability to deliver applications and…
-
2
votes1
answer350
viewsA: Entity Framework: Data Model with column with the largest number of characters possible
You can use System.ComponentModel.DataAnnotations.Schema.ColumnAttribute to define that your property will be created as text in the Database. [Column(TypeName = "text")] public string…
-
0
votes1
answer83
viewsQ: How to identify server updates with Service Worker?
Is it possible to identify that there was an update on the server, that is, there was an update on the page (HTML) or in the style (CSS), and request to the server to fetch the updated data? If yes,…
-
2
votes1
answer566
viewsA: Date validation with Jquery
First you will need to add one id the field of date of birth: @Html.EditorFor(model => model.DataNascimento, new { htmlAttributes = new { @class = "form-control data", id = "DataDeNascimento" }…
-
1
votes1
answer26
viewsA: Error accessing array indices inside a LINQ expression
To fix the problem use a temporary variable to store the value in the index i of the matrix tmp: var tempValue = tmp[i]; var metereologias = db.Metereologias.Where(b =>…
-
0
votes2
answers317
viewsA: Error creating database by Visual Studio 2015
As the error message itself says: you need to have Localdb or SQL Server Express installed and running on your local computer, that is, on your machine. I believe you do not have the program(s)…
-
0
votes1
answer95
viewsA: Error while consuming Glassfish + Jersey REST web service with date that returns an xml
I solved my problem by making use of Annotation @XmlJavaTypeAdapter and creating a DateFormatterAdapter to return the date in a valid format to consume on my android app yyyy-mm-dd. public class…
-
2
votes2
answers210
viewsA: Calculate duplicate input value
Below is the solution of your problem with my considerations: $(document).ready(function() { clonar(); $("#mais").on("click", clonar); }); function calcularValorTotal() { var $aliquota = $(this);…
-
1
votes2
answers111
viewsA: Error When Generating Scaffold
You are forgetting to import the following libraries System.Linq and System.Data.Entity. Add the code below to the top of your class: using System.Linq; using System.Data.Entity; Updated Note that,…
-
3
votes2
answers676
viewsA: Installation of Firebase in Android Studio
The Cloud tab (which contains a checkbox to add Firebase to a project) has been removed in Android Studio 2.2. Android Studio 2.2 has a full wizard to help you integrate Firebase. You can find it in…
-
5
votes2
answers476
viewsA: How to pass parameters to an array in javascript?
You can pass the coordinates inside the Locations variable as follows: locations.push( { lat: -30.851700, lng: 150.363100 } ); Updated Through the resource push you will add the item at the end of…
javascriptanswered Lucas Kauer 717 -
0
votes1
answer95
viewsQ: Error while consuming Glassfish + Jersey REST web service with date that returns an xml
I need to consume a web service (WS) REST on my android app. The web service was done with glassfish, jersey and the Hibernate ORM to communicate with the database. Below is the WS code: Vegetarian…
-
1
votes1
answer508
viewsA: Pass lambda statement by parameter - C# - Entity
In order to be able to say with more certainty what the code would look like in its context I will need the complete User repository class. But below is an idea of how the declaration of the method…