语言

Menu
Sites
Language
Charts not generated

Hi, i'm developping an application that needs to generate charts, so i used Highchart.js, but when i execute the app on the Tizen Web Application i receive this error : js/charts.js (183) :ReferenceError: Can't find variable: Highcharts . I added these lines on Chart.html file : 

<script src="http://code.highcharts.com/highcharts.js"></script>

<script src="http://code.highcharts.com/modules/exporting.js"></script>
and in the charts.js :
 $(function() {
// Radialize the colors
 console.log("charts");
Highcharts.getOptions().colors = Highcharts.map(
Highcharts.getOptions().colors, function(color) {
return {
radialGradient : {
cx : 0.5,
cy : 0.3,
r : 0.7
},
stops : [
[ 0, color ],
[
1,
Highcharts.Color(color).brighten(-0.3).get('rgb') ] // darken
]
};
});
// Build the chart
$('#container').highcharts(
{
chart : {
plotBackgroundColor : null,
plotBorderWidth : null,
plotShadow : false
},
title : {
text : 'Total expense for each target.'
},
tooltip : {
pointFormat : '{series.name}: <b>{point.percentage}%</b>',
percentageDecimals : 1,
fontSize : '20px'
},
plotOptions : {
pie : {
allowPointSelect : true,
cursor : 'pointer',
dataLabels : {
enabled : true,
color : '#000000',
fontSize : '20px',
connectorColor : '#000000',
formatter : function() {
return '<b>'
+ this.point.name
+ '</b>: '
+ Math
.round(this.percentage)
+ ' %';
}
}
}
},
series : [ {
type : 'pie',
name : 'Statistics Per Category',
data : [ [ 'Add', peradd ],
[ 'Retreat', perretreat ], {
name : 'Loan',
y : perloan,
sliced : true,
selected : true
}, [ 'Debt', perdebt ] ]
} ]
});
});
I added in the config.xml this line : <access origin="http://code.highcharts.com/" subdomains="true"/> and it doesn't work too. But when i execute the app with the Tizen web simulator application and it works perfectly, 
Anyone have any ideas what might be the problem? 
编辑者为: Brock Boland 17 3月, 2014 原因: Paragraph tags added automatically from tizen_format_fix module.

响应

10 回复
Raghavendra Reddy Shiva
Are you able to access internet on the emulator (or device) ? It might be issue with internet access on your emulator (or device), as you mentioned the app works perfectly on simulator. If you are on network and still having issues, then please share the html outline code to understand what's going wrong.
wiem hjiri
I'm not able to access to the internet on the emulator, could you please tell me how can I fix that?
Raghavendra Reddy Shiva
The Emulator uses the host network proxy when connecting to the Internet. So if your network has a proxy server, then change the proxy address in Internet Explorer (in windows) and restart the Emulator. Refer below link (Check under Proxy Address), https://developer.tizen.org/help/topic/org.tizen.gettingstarted/html/guides/settings_menu.htm
karray gargouri
Hi everyone, I am facing the same problem, and I've read your posts. But what if I am not using a proxy (Honestly I don't know if i am using one or not or should I changing it!)... I mean is there any other alternative to follow? Thanks
wiem hjiri
Thank you for your response, but i didn't have a proxy connection. So i tried to create one and putted the address of the emulator mentionned in the log file here: C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms but the emulator still not connected to the internet. How can i fix that?
Lakshmi Grandhi
Hi, can you share your emulator logs without modifying it
Lakshmi Grandhi
Are you using internet using LAN or WIFI
wiem hjiri
I'm using wifi, here is the emulator log : [info:qemu:main]Emulator start !!! [info:qemu:main]lcd width option = 720 [info:qemu:main]lcd height option = 1280 [info:qemu:emul_state]emulator graphic resolution = 720x1280 [info:qemu:main]* Board name : Maru [info:qemu:main]* Package Version: 1.5.70 [info:qemu:main]* Package Maintainer: Yeong-Kyoon Lee [info:qemu:main]* Git Head : 9eacedd4d94f6513837b4c0f63776af47426db35 [info:qemu:main]* User name : WIEM [info:qemu:main]* Host name : WIEM-PC [info:qemu:main]* Build date : 2013-07-17 20:16:45 [info:qemu:main]* Current time : 2013/08/22 00:30:35 [info:qemu:main]* Host sdl version : (1, 2, 14) [info:emulator:osutil]* Windows [info:emulator:osutil]* MajorVersion : 6, MinorVersion : 1, BuildNumber : 7601, PlatformId : 2, CSDVersion : Service Pack 1 [info:emulator:osutil]* Processor type : 586, Number of processors : 4 [info:emulator:osutil]* Total Ram : 4053864 kB, Free: 1181200 kB [info:qemu:main]Prepare running... [info:qemu:main]tizen_target_img_path: C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2\emulimg-emulateur2.x86 qemu args: ========================================= C:\tizen-sdk\tools\emulator\bin\emulator-x86.exe -drive file=C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2\emulimg-emulateur2.x86,if=virtio,index=1 -boot c -append console=ttyS0 video=uvesafb:ywrap,720x1280-32@60 dpi=3160 ip=10.0.2.16::10.0.2.2:255.255.255.0::eth0:none 5 vm_name=emulateur2 -serial file:C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2\logs\emulator.klog -m 512 -M maru-x86-machine -net nic,model=virtio,macaddr=00:50:56:C0:00:01 -soundhw all -usb -device virtio-touchscreen-pci -vga maru -bios bios.bin -L C:\tizen-sdk\tools\emulator\data\bios -kernel C:\tizen-sdk\tools\emulator\data\kernel\bzImage.x86 -net user -rtc base=utc -drive file=C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2\swap-emulateur2.img,if=virtio,index=2 -enable-hax -enable-gl -device virtio-esm-pci -device virtio-hwkey-pci -max-touch-point 10 qemu args: ========================================= skin args: =[info:qemu:main]qemu main start! ======================================== width=720 height=1280 skin.path=C:\tizen-sdk\tools\emulator\skins\emul-general-3btn skin args: ========================================= hax_disabled 0 ram_size 20000000 device fd:252 End of VM create, id 0 HAX is working and emulator runs in fast virt mode. maxTouchPoint:10 [info:qemu:main]Prepare maru specified kernel command line [info:qemu:sdb]port(26101) listen ok [info:qemu:sdb]sdb port is 26100 [err:emulator:osutil]Failed to query value from Software\Microsoft\Windows\CurrentVersion\Internet Settings\AutoConfigURL [info:emulator:osutil]proxy value: 10.0.2.16:26100 [info:emulator:osutil]all protocol uses the same proxy server: 10.0.2.16:26100 [info:emulator:osutil]port 26100 is not used. [info:emulator:osutil]port 26110 is not used. [info:emulator:osutil]port 26120 is not used. [info:emulator:osutil]port 26130 is not used. [info:emulator:osutil]port 26140 is not used. [info:emulator:osutil]port 26150 is not used. [info:emulator:osutil]port 26160 is not used. [info:emulator:osutil]port 26170 is not used. [info:emulator:osutil]port 26180 is not used. [info:emulator:osutil]port 26190 is not used. [info:qemu:sdb]SDBD established on port 26101 [info:qemu:sdb]redirect [tcp:26101:10.0.2.16:26101] success [info:qemu:sdb]Port(26101/tcp) listen for SDB [info:qemu:sdb]redirect [tcp:26103:10.0.2.16:3577] success WGL_ARB_render_texture supported! Render to texture supported, add attributes in array! GL VENDOR NVIDIA Corporation GL RENDERER GeForce 310M/PCI/SSE2 GL VERSION 3.1 NVIDIA 188.98 glFormat: 0x000080E1 glType: 0x00001401 [Webcam] Device name : CyberLink Webcam Splitter [Webcam] PixelFormat: YUY2, 320x240 [Webcam] PixelFormat: YUY2, 640x480 [Webcam] PixelFormat: YUY2, 160x120 [Webcam] PixelFormat: YUY2, 800x600 [Webcam] PixelFormat: YUY2, 1280x960 [Webcam] PixelFormat: YUY2, 1600x1200 [Webcam] RGB BitCount: 24, 320x240 [Webcam] RGB BitCount: 24, 640x480 [Webcam] RGB BitCount: 24, 160x120 [Webcam] RGB BitCount: 24, 800x600 [Webcam] RGB BitCount: 24, 1280x960 [Webcam] RGB BitCount: 24, 1600x1200 [Webcam] Elapsed time : 0.055003 [info:qemu:main][Webcam] Webcam support was enabled. [info:qemu:main]kernel command : console=ttyS0 video=uvesafb:ywrap,720x1280-32@60 dpi=3160 ip=10.0.2.16::10.0.2.2:255.255.255.0::eth0:none 5 vm_name=emulateur2 sdb_port=26100, http_proxy=10.0.2.16:26100 https_proxy=10.0.2.16:26100 ftp_proxy=10.0.2.16:26100 socks_proxy=10.0.2.16:26100 dns1=10.0.2.3 gles=1 yagl=0 enable_cam=1 [info:qemu:maru_overlay]Maru overlay was initailized! [info:tizen:qemu_audio]Host audio out [winwave] is normal. [info:qemu:marucodec][codec_init] device create [info:qemu:marucodec][codec_initfn] device init [info:qemu:touchscreen]initialize the touchscreen device [info:qemu:touchscreen]virtio touchscreen is added to qemu mouse event handler [info:qemu:virtio-esm]initialize virtio-esm device [info:qemu:hwkey]initialize the hwkey device [info:tizen:camera_pci][marucam_initfn] camera device was initialized. [info:tizen:display]init qemu display [info:tizen:maru_sdl]qemu_ds_sdl_resize = (640, 480) [info:tizen:maru_sdl]create blank screen = (720, 1280) *********ReSet hax_vcpu->emulation_state [info:qemu:main]Prepare maru specified feature [info:qemu:main]call construct_main_window [info:qemu:main]construct main window [info:qemu:skin_server]There is no .skinconfig.properties. skin_config_path:C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2\.skinconfig.properties [info:qemu:skin_server]skin params key:width, value:720 [info:qemu:skin_server]skin params key:height, value:1280 [info:qemu:skin_server]skin params key:skin.path, value:C:\tizen-sdk\tools\emulator\skins\emul-general-3btn [info:qemu:skin_server]ignore_heartbeat:0 [info:qemu:skin_client]sleep for ready. count:1 [info:qemu:skin_server]run skin server [info:qemu:skin_server]success to bind port[127.0.0.1:59461/tcp] for skin_server in host [info:qemu:skin_server]skin server start...port:59461 [info:qemu:skin_server]start accepting socket... [info:qemu:skin_client]run skin client [info:qemu:skin_client][skin args 0] width=720 [info:qemu:skin_client][skin args 1] height=1280 ad [info:qemu:skin_client][skin args 2] skin.path=C:\tizen-sdk\tools\emulator\skins\emul-general-3btn [info:qemu:skin_client]This process is running under WOW64. [info:qemu:skin_client]bin directory : C:\tizen-sdk\tools\emulator\bin\ [info:qemu:guest_server]start guest server thread. [info:qemu:skin_client]command for swt : "C:\Program Files\Java\jre7\bin\java" -jar -Djava.library.path="C:\tizen-sdk\tools\emulator\bin" "C:\tizen-sdk\tools\emulator\bin\emulator-skin.jar" svr.port="59461" uid="0" vm.path="C:\Users\WIEM\AppData\Local\tizen-sdk-data\emulator-vms\vms\emulateur2" net.baseport="26100" max.touchpoint=10 width=720 height=1280 skin.path=C:\tizen-sdk\tools\emulator\skins\emul-general-3btn [info:qemu:guest_server]success to bind port[127.0.0.1:26103/udp] for guest_server in host [info:qemu:guest_server]guest server start...port:26103 [info:qemu:skin_client]wait for single object.. [info:tizen:maru_sdl]qemu_ds_sdl_resize = (720, 400) [info:tizen:maru_sdl]create blank screen = (720, 1280) [info:qemu:skin_server]accept client : client_sock:1148 [info:qemu:skin_server]== RECV read_cnt:12 uid:0, req_id:1, cmd:1, length:22 data read_cnt:22 RECV_START == [info:qemu:emul_state]emulator window scale_factor = 0.500000 [info:qemu:skin_operation]start_display handle_id:134578, lcd size:720x1280, scale_factor:0.500000, rotation_type:0 [info:qemu:emul_state]emulator window scale_factor = 0.500000 [info:tizen:maru_sdl]maru sdl initialization = 0 [info:tizen:maru_sdl]register SDL environment variable. (SDL_WINDOWID = 134578) [info:qemu:emul_state]emulator graphic resolution = 720x1280 [info:qemu:maru_finger]multi-touch state initialization [info:qemu:maru_finger]maxTouchPoint=10 [info:tizen:maru_sdl]sdl update thread create [info:tizen:maru_sdl]Set up a video mode with the specified width, height and bits-per-pixel [info:tizen:maru_sdl]qemu_ds_sdl_resize = (720, 1280) [info:qemu:maru_brightness]brightness_reg_read: brightness_level = 100 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server]notify_sensor_daemon_start [err:qemu:guest_server]!!! unknown command : 2 [info:qemu:skin_server]notify_sensor_daemon_start [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 1 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 Render to texture supported, add attributes in array! Render to texture supported, add attributes in array! Render to texture supported, add attributes in array! [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 Render to texture supported, add attributes in array! Render to texture supported, add attributes in array! [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:158 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:139 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:139 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 Render to texture supported, add attributes in array! [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 Render to texture supported, add attributes in array! Render to texture supported, add attributes in array! [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server][HB] recv_heartbeat_count:2 Render to texture supported, add attributes in array! [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server][HB] recv_heartbeat_count:2 Render to texture supported, add attributes in array! Render to texture supported, add attributes in array! [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:139 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:139 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 1 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_operation]request_close [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:116 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 1 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:116 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 1 [info:qemu:skin_server][HB] recv_heartbeat_count:2 [info:qemu:skin_operation]request_close [info:qemu:skin_operation]do_hardkey_event event_type:1, keycode:116 [info:qemu:maru_brightness]brightness_level : 0 [info:qemu:maru_brightness]brightness_off : 1 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_operation]do_hardkey_event event_type:2, keycode:116 [info:qemu:maru_brightness]brightness_level : 100 [info:qemu:maru_brightness]brightness_off : 0 [info:qemu:skin_server]shutdown_skin_server [info:qemu:skin_server]send shutdown to skin. [info:qemu:skin_server]== RECV read_cnt:12 uid:0, req_id:4570, cmd:999, length:0 RECV_RESPONSE_SHUTDOWN == [info:qemu:skin_server]stop receiving current client socket. [info:qemu:skin_server]close server socket normally. [info:qemu:skin_server]skin client sent normal shutdown response. [info:qemu:guest_server]shutdown_guest_server. [info:tizen:display]fini qemu display [info:qemu:maru_finger]clear multi-touch [info:qemu:maru_finger]clear multi-touch [err:qemu:guest_server]fail to recvfrom in guest_server. fail to recvfrom in guest_server.:: No error [info:qemu:skin_server][HB] stop heart beat.
Lakshmi Grandhi
Hi, I don't see any issue with proxy connection, it has been set well. I have raise a bug in JIRa with your log file https://bugs.tizen.org/jira/browse/TSDK-173. Follow it for solution [info:emulator:osutil]proxy value: 10.0.2.16:26100 [info:emulator:osutil]all protocol uses the same proxy server: 10.0.2.16:26100 [info:emulator:osutil]port 26100 is not used. [info:emulator:osutil]port 26110 is not used. [info:emulator:osutil]port 26120 is not used. [info:emulator:osutil]port 26130 is not used. [info:emulator:osutil]port 26140 is not used. [info:emulator:osutil]port 26150 is not used. [info:emulator:osutil]port 26160 is not used. [info:emulator:osutil]port 26170 is not used. [info:emulator:osutil]port 26180 is not used. [info:emulator:osutil]port 26190 is not used. [info:qemu:sdb]SDBD established on port 26101
karray gargouri
I use a LAN connection!