Arturo
October 5, 2022, 5:31pm
1
Hi dear commuty,
I have an issue and I don't know how to fix it. I use giviz to get some values from an spreadsheet, in the next image I will show the values.
The issue is:
In the colum H, we have numbers and letters. ex. 98, 5200, no corre & ill
then when I take the values in a list view, let me show you the list view.
how can we have all the values of colum H. because we can only see the numbers but not the letters, in the last row we see PushPull, 9, Marca código and , ....... but we can't see tarimas because are letters
I will show the blocks used to extract the information
By chance somebody knws how to fix it to see all the values numbers and letters ?
thanks in advance
What do you get in Web.GotText - responseContent?
Have you checked this @TIMAI2 tutorial?
INTRO
gviz is an abbreviation for Google Visualization API which is used to access google sheets and google charts, among other things. In this tutorial we will focus on getting and querying data on google sheets, to work with or display this data in...
Arturo
October 5, 2022, 7:12pm
3
@Juan_Antonio Hi, yes did.
this is the web got.text
Put a Label on Web.GotText and see what you get.
Arturo
October 5, 2022, 7:25pm
5
The same Issue, we can not see thé letters
with push pull it does not appear the world tarimas
TIMAI2
October 5, 2022, 8:41pm
6
You do not show your query....
Arturo
October 5, 2022, 8:44pm
7
sorry, I'll show the URL and the query
https://docs.google.com/spreadsheets/d/1Cu77ER5zL6tieN6jQSpQAP0wtF8PNXvdCe6xmq_rZXc/gviz/tq?tqx=out:csv&tq=SELECT E, F, G, H, I WHERE A = 'Reportado'
you know even when we test this in the browser show this
column D only we can see the numbers
TIMAI2
October 5, 2022, 8:57pm
8
It seems to work OK for numbers and text in column F. What is different about column H ?
Arturo
October 5, 2022, 9:02pm
9
I am trying to see, but I have not realise
for colum F manualy I chage the format
as text wiout format
but is there a way to do that automatizally for all the row?
TIMAI2
October 5, 2022, 9:08pm
10
Google Sheets will tend to set the format of a cell based upon the content which a puts applies.
You run an apps script to set the format after an entry is made...
Alternatively, you could enter all the numbers as text, by placing an apostrophe before the number:
'1234
Arturo
October 5, 2022, 9:24pm
11
TIM,
Is like this the code that I need to introduce in apps script ?
if (Funcion == 'ENVIAR' ) {
var registro = e.parameter.REGISTRO.split(',');
sh.appendRow(registro);
sh.getDataRange().setNumberFormat(String numberFormat)
return ContentService.createTextOutput("New record created");
TIMAI2
October 5, 2022, 9:31pm
12
See here
I suggest, if you cannot set just the cell, then to set the column.
1 Like
Arturo
October 5, 2022, 9:37pm
13
thanks
so like this?
if (Funcion == 'ENVIAR' ) {
var registro = e.parameter.REGISTRO.split(',');
sh.appendRow(registro);
var column = sheet.getRange("H2:H");
column.setNumberFormat("@");
return ContentService.createTextOutput("New record created");
}
TIMAI2
October 5, 2022, 9:37pm
14
Try it, see what happens...
Arturo
October 5, 2022, 9:39pm
15
ok, I'll do, and then I go back
no, I did and I do not works
looks that the code is not running
TIMAI2
October 5, 2022, 9:50pm
16
sh.getRange("H2:H")
(not sheet.)
1 Like
Arturo
October 5, 2022, 10:03pm
17
thanks TIM, I really apreciate your help, now it works
system
Closed
October 12, 2022, 10:04pm
18
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.