Posts by Roberto Gomes • 455 points
25 posts
-
4
votes1
answer75
viewsQ: C# float++ and float-
I used the following code snippet: bool plus = false; int index = 0; index = plus ? index++ : index--; the index result is 0 and do not know why, when I do the way below it works: index += plus ? 1…
c#asked Roberto Gomes 455 -
0
votes0
answers48
viewsQ: Symbol > appears at the end of XML
I have an XML document that serves for a program in Java save some values that will be read by another in C#. It’s not the best way to exchange values between languages (that’s what happened, but I…
-
2
votes2
answers320
viewsQ: List tables in a single SQL Server query
I need a query that returns to each map the players who had battles on it, the amount of battles each player had (on the respective map), the total time played (per player on the respective map),…
sql-serverasked Roberto Gomes 455 -
0
votes0
answers44
viewsQ: Sending values to BD makes the application too slow
I created a program in java to capture the movement of a sensor and then send the data to a database, so that later the movement is accessed by another machine in real time (or almost) elsewhere.…
-
0
votes1
answer450
viewsQ: Jframe does not update until function of button finish
When I click the button it calls a method, and until this method finishes the Jframe does not update the program is in the image below private void…
-
0
votes0
answers29
viewsQ: Library error while running outside the IDE
I’m connecting the application to a bluetooth device through a library, runs perfectly within the Netbeans, but then when I’m going to run through. jar gives this error: Exception in thread "main"…
-
0
votes0
answers242
viewsQ: Java library Linker error (Netbeans)
I’m having trouble with a library that I imported. What I did was simply extract the zip file from the library and then in Libraries I used Add Jar/Folder to import the bibliotca to the project. The…
-
3
votes1
answer78
viewsQ: What "[ ]" means in the method declaration
I have the following method public BITalinoFrame[] Read(int nbSamples) { try { return device.ReadFrames(nbSamples); } catch (Exception ex) { WriteLog("Error reading the frames: " + ex.Message); }…
c#asked Roberto Gomes 455 -
0
votes2
answers2273
viewsA: How to make Sprite sheet exchange at Unity without having to do more animations?
What you can do is create a Script like the following: public int spriteAtual; public Sprite[] sprites; private SpriteRenderer img; void Start { img =…
-
0
votes2
answers335
viewsA: How to specify object in getcomponent?
I believe Raphael’s answer is right, you just need to make the variables public, so in the inspector, you can just drag the corresponding animations. I believe it’s the easiest and easiest way. You…
-
0
votes1
answer225
viewsQ: Apply force by clicking and dragging Unity
Good morning, I’m a beginner in Unity so sorry if I talk nonsense haha I am developing a game where I need to put a ball in a basket, what I am not able to do is to click and drag the ball to apply…
-
0
votes1
answer2173
viewsQ: Unity 2d - Enemy follow player
Well, I’m having trouble getting the enemy to follow the player, I did the code below: public class folow : MonoBehaviour { public Transform target;//set target from inspector instead of looking in…
-
1
votes1
answer76
viewsQ: java.lang.Nullpointerexception in method
package view; import br.com.genius.dal.ModuloConexao; import java.sql.*; import java.util.ArrayList; import javax.swing.JOptionPane; public class Chamada_ListaCompra extends…
-
0
votes2
answers57
viewsQ: Table only fills the column title
I wrote the method below: public void setListaCompra() { String sql = "SELECT * FROM\n" + "(\n" + " SELECT \n" + " produtos.id AS id, \n" + " nome_produto AS Nome, \n" + "…
-
2
votes2
answers609
viewsQ: How to use WHERE function in column created from a formula?
I wrote that code: SELECT produtos.id AS id, nome_produto AS Nome, SUM(estoque.Estoque_produto) AS Estoque, Periodicidade AS Periodicidade, produtos.estoquemax_produto AS 'Média de venda mensal',…
mysqlasked Roberto Gomes 455 -
6
votes1
answer227
viewsQ: List Mysql tables and filter by date
I need only a final value, the commission value for products with extra commission in a date range and a specific seller, the information is in 3 tables in the BD: Below is the table 'Commission…
mysqlasked Roberto Gomes 455 -
1
votes1
answer100
viewsQ: Error in query syntax in Preparestatement
I’m getting this error message and I can’t find why: You have an error in your SQL syntax; check the manual that Corresponds to your Mysql server version for the right syntax to use near '?,? ,? )'…
-
1
votes1
answer83
viewsA: Data problem in mysql and java
I managed to fix the code, I realized I was calculating the value of the previous month, I solved the problem by adding 1 in jMonthChooser1.getMonth(), the problem was that the first month of the…
-
1
votes1
answer83
viewsQ: Data problem in mysql and java
I’m trying to use the date of a jYearChoser and a jMonthChoser to search for a full month sale, already tested at the Mysql prompt and worked perfectly with the command below: SELECT…
-
1
votes1
answer1244
viewsQ: How do I change the Look and Feel of an app?
Can anyone explain to me how I change the layout of my application windows? I was building the app and testing by the method main normally, but since it took me a long time to wait to connect to the…
-
1
votes0
answers80
viewsQ: Change column header with formula
I searched infinity on the internet and did not find, hope someone can help me, I have the following table: the numbers -1, -2, -3... represent the months, that is, past month(-1), past tense(-2)...…
mysqlasked Roberto Gomes 455 -
1
votes2
answers39
viewsQ: Filter result by date
My problem is, when I run the command below: SELECT Id_produto AS Produto, Quantidade AS quantidade, genius.vendas.data_venda AS Periodo FROM genius.itens_venda LEFT JOIN genius.vendas ON vendas.Id…
mysqlasked Roberto Gomes 455 -
0
votes1
answer224
viewsQ: relationship between SQL tables
I have the following problem, I have two stocks in my company, so I have two values for the stock, and the stock record looks something like this: as the picture shows, each product has two records,…
-
5
votes1
answer537
viewsQ: change output type to currency
I have a code that gives me two columns, Expense and Total, what I can not get is that in the output of the totals it gives me in currency format (R $ 1,000,00). the code is this: SELECT nome_evento…
mysqlasked Roberto Gomes 455 -
1
votes1
answer410
viewsQ: Get totals by date range, relating to additional table
The case is as follows, I have a table in Mysql referring to a company box, and I am creating a table in JAVA that will be a cost center. The database table has the columns: id | data | descricao |…
mysqlasked Roberto Gomes 455