[nsb-appstudio] How to change Language options in datatable bootstrap

32 views
Skip to first unread message

oscarquiroscoto@yahoo.com [nsbasic-app]

unread,
Apr 8, 2017, 11:59:49 AM4/8/17
to nsbas...@yahoogroups.com
 

I needo to change Language options in datatable bootstrap, but I do not know how to do it, I saw the documentation in https://datatables.net/manual/i18n and https://datatables.net/plug-ins/i18n/Spanish but it does not work, or I do not know how to apply it to my project vb.



__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

'George Henne' gh@nsbasic.com [nsbasic-app]

unread,
Apr 8, 2017, 4:11:49 PM4/8/17
to Nsbasic App
 

Add this function to the end of your code:

JavaScript
var spanish;

function DataTable_language(id) {
spanish = {
"sProcessing": "Procesando...",
"sLengthMenu": "Mostrar _MENU_ registros",
"sZeroRecords": "No se encontraron resultados",
"sEmptyTable": "Ningún dato disponible en esta tabla",
"sInfo": "Mostrando registros del _START_ al _END_ de un total de _TOTAL_ registros",
"sInfoEmpty": "Mostrando registros del 0 al 0 de un total de 0 registros",
"sInfoFiltered": "(filtrado de un total de _MAX_ registros)",
"sInfoPostFix": "",
"sSearch": "Buscar:",
"sUrl": "",
"sInfoThousands": ",",
"sLoadingRecords": "Cargando...",
"oPaginate": {
"sFirst": "Primero",
"sLast": "Último",
"sNext": "Siguiente",
"sPrevious": "Anterior"
},
"oAria": {
"sSortAscending": ": Activar para ordenar la columna de manera ascendente",
"sSortDescending": ": Activar para ordenar la columna de manera descendente"
}
};
id.settings.language = spanish;
}
End JavaScript

Also, call the function before you draw the table for the first time:

function Main()
DataTable_language(DataTable1)
updateTable()
End function

George Henne
NS BASIC Corporation
http://www.nsbasic.com


>I needo to change Language options in datatable bootstrap, but I do not
>know how to do it, I saw the documentation in https://datatables.net/
>manual/i18n and https://datatables.net/plug-ins/i18n/Spanish but it does
>not work, or I do not know how to apply it to my project vb.
>
>
>
>
>
>

__._,_.___

Posted by: "George Henne" <g...@nsbasic.com>

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

oscarquiroscoto@yahoo.com [nsbasic-app]

unread,
Apr 8, 2017, 9:39:52 PM4/8/17
to nsbas...@yahoogroups.com
 

Thanks, it works.
But, it only works on the table builder only works on function main.
How do I make it work at any time, since the data varies according to the needs or filters.

function Main()
  DataTable_language(DataTable1)
  updateTable()
  'work
End function

funciton updateTable()
  columns1 = [{title:"Nombre"},{title:"Salario"}]
  data1 = [["Oscar", "$22"]]
  DataTable1.settings.columns = columns1
  DataTable1.settings.data = data1
  DataTable1.build()

end funciton

Function Button1_onclick()
'  does not work

  updateTable()
end Function

Function Button2_onclick()
'  does not work

  columns1 = [{title:"1-Nombre"},{title:"2-Salario"}]
  data1 = [["1-Oscar", "2-$22"]]
  DataTable1.settings.columns = columns1
  DataTable1.settings.data = data1
  DataTable1.build()
end Function

__._,_.___

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

'George Henne' gh@nsbasic.com [nsbasic-app]

unread,
Apr 9, 2017, 6:59:24 AM4/9/17
to Nsbasic App
 

Are you having trouble with changing the names of the columns, or the default language of the table itself?


George Henne
NS BASIC Corporation
http://www.nsbasic.com

__._,_.___

Posted by: "George Henne" <g...@nsbasic.com>

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

oscarquiroscoto@yahoo.com [nsbasic-app]

unread,
Apr 10, 2017, 10:30:24 AM4/10/17
to nsbas...@yahoogroups.com
 

Thank you if it works.

__._,_.___

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___
Reply all
Reply to author
Forward
0 new messages