问题描述
我是Jscript.net新手,我正在尝试读取一个对象,但我现在不知道对象x到底是什么.
实际上,我从共享点站点成功读取了其他一些valeus,但是事实证明,唯一失败的变量是x,事实证明x是一个对象.起初,我以为[object Object]不会返回任何东西,直到我进行了网络跟踪为止.要封装在对象内的x接缝的值.但是我不知道如何从一个对象中得到我的价值.
如果我
i am a Jscript.net newbie i am trying to read an object I do not k now exactly what the object x is.
in fact i read some other valeus successfully from a sharepoint site, but it turns out the only variable that fails is x, it turns out that x is an object. At first i thought [object Object] didnt return anything untill i did a network trace; the values of x seam to be encapsulated inside an object. But i dont know how to get my values out of an object.
if i do
alert(x);
我得到结果: [对象对象]
如果我
I get result : [object Object]
if i do
alert("myObject is " + x.toSource()); // but this works only in firefox
我得到结果:({$ L_1:3,$ b_1:"tpc-102"})
我想要得到的就是这些值.
不仅可以在Firefox中工作,还可以在Internet Explorer中工作
3
tpc-102
最好为它们分配一些变量,例如
a = 3
b = tpc-102
如果您想回答这个问题,请帮助我发掘这些价值观;将我指向许多网站和书籍可能是以后的想法.我不害怕学习,但是我已经读了很多书,但我都没有发现[对象对象]问题.甚至与Google一起寻找都没有给我任何提示.
I get result : ({$L_1:3, $b_1:"tpc-102"})
What i want to get in return is just these values.
And working in not only firefox also internet explorer
3
tpc-102
preferably having some variables assigned to them like
a = 3
b = tpc-102
If you like to answer this help me to get these values out; pointing me to many websites and books is maybe an idea for later; i''m not afraid of learning but i consumed a lot books allready in none of these i found the [object Object] problem. And even looking with google didnt gave me clues.
推荐答案
这篇关于Javascript如何从对象中读取的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!