Posts by Felipe Chagas • 318 points
19 posts
-
0
votes1
answer17
viewsA: have to obtain the numeric value of a tag without being by id, in case a class and then divide by another number and show inside the site
The getElementsByClassName returns an array and the object containing its text is textContent, see this example. var url = document.getElementById('this-id').textContent alert(url); var url =…
javascriptanswered Felipe Chagas 318 -
0
votes1
answer534
viewsA: How to pass a Javascript Array to PHP
Assuming you can use jQuery and a form is not an option, you can try the Ajax method: $.ajax({ url: '/caminho/do/seu/script.php', type: 'POST', dataType: 'JSON', data: newArray, success:function(e){…
-
0
votes1
answer73
viewsQ: Imap works only on CLI
The PHP imap extension works only via the command line. When calling the script from another place the return is: PHP Fatal error: Uncaught Error: Call to undefined function imap_open() When running…
-
0
votes1
answer387
viewsQ: JSON returns STRING instead of ARRAY
The following code is returning an array as a string and therefore I cannot distribute the data to popular Flot Chart. The PHP code: <?php include_once("config.php"); $viagemid = $_POST['id'];…
-
1
votes2
answers72
viewsA: Macro problem that performs dynamic sums and non-continuous intervals
Try to add up the amounts as you count them. Dim soma As Double soma = 0 For i = 1 To b If balancete.Cells(i + 1, 1) = 10 Then cont_10 = cont_10 + 1 soma = soma + balancete.Cells(i + 1, 1).Value…
-
1
votes1
answer340
viewsA: Combobox does not update and accepts wrong values
Combobox and data validation are different things. Try to use data validation, here is a very simple code to prevent improper data from being typed into the cell and create a combobox in the…
-
0
votes1
answer114
viewsA: Consolidate macros
Here’s an excerpt of the code I use to basically do what you want: Opens a selection window User selects a spreadsheet Excel opens the selected worksheet, copies the data and closes the selected…
-
1
votes1
answer42
viewsA: Does Excel include columns alone from a range?
You can use the Excel Dynamic Table feature for this. In it you can transform this data into an array where the name will be the column and the score the corresponding value, this feature calculates…
excelanswered Felipe Chagas 318 -
0
votes1
answer38
viewsQ: Entering IF with missed criteria
In the code, step to the variable $acesso what would be the value extracted from the user’s session (just for testing). And I have 3 blocks of IF, each checking different conditions for the same…
phpasked Felipe Chagas 318 -
0
votes1
answer31
viewsA: Insert date in bd with JDBC Google Script
I used the following to make the conversion: var data = Jdbc.newTimestamp(base.getRange(i,3).getValue());
-
0
votes1
answer31
viewsQ: Insert date in bd with JDBC Google Script
I am trying to write several data in the database (Mysql), but in the data of the date type the following error: Unable to find setTimestamp(number,string) method. (line 32, file "Code") The code…
-
0
votes1
answer388
viewsA: Copy cells to another Worksheet if they do not exist
Come on. If I understood correctly, would this NIF be the index of the spreadsheet? In this case the following code should help you: Sub copiar() lRow1 = Plan1.Cells(Rows.Count, 1).End(xlUp).Row…
-
1
votes1
answer706
viewsQ: Popular a select generated by javascript
I am copying fields from a form with javascript, but in this form two input sane select and the option are generated from the result of a query. When copies are created query do not rotate and…
-
2
votes1
answer79
viewsQ: Querys have stopped working
I recently made a change to the table and after that SELECT and INSERT INTO stopped working. At first the INSERT INTO could not include data in the last column that includes (centid), returned…
-
1
votes2
answers1241
viewsA: How to create a macro that enters the site and takes the data from the last day?
You can scan the site looking for the id of getElementsById(). From what I saw on the site the id is imagenet-indicator1 and imagenet-indicator2. I didn’t test the code, but it would be something…
-
1
votes1
answer233
viewsA: Range.Paste Runtime error when pasting web data
I was able to solve the problem by changing the format I was pasting. The code looked like this: Set ieTable = IE.document.getElementById("itens") If Not ieTable Is Nothing Then Set clip = New…
-
2
votes3
answers3061
viewsA: How to use a Command Button inserted in the Spreadsheet in the VBA code?
On the click counter, you can make it disappear into any cell when the user clicks on the button. For example: Sub Button1_Click() Sheet1.Cells(1, 1).Value = Sheet1.Cells(1, 1).Value + 1 End Sub…
-
4
votes1
answer5547
viewsA: Importing data from a web page to Excel via VBA
Just need to replace the block of the for that you scored for this: IE.document.getelementbyid("csSB_Search_FirstName_ID").Value = myState I used the same variable MyState not to complicate it, but…
-
4
votes1
answer233
viewsQ: Range.Paste Runtime error when pasting web data
Hello. I am extracting some data from an html table of an ERP that due to limitations lead me to it. Anyway, the problem consists of, when copying the table and trying to glue it with range.Paste or…