shalu pareek

Greenhorn
+ Follow
since Nov 14, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by shalu pareek

Hi i am using axaj to get the values for the dropdown. i have values in the form of pair as docid and its name. the name i want to display in the drop down and its value should be docID. so for this i have below code:

//Insert the values
var resultStringArr = new Array();
//reslutSringArrdocid= resultString.split('=');
resultStringArr = resultString.split(",");
for(var n = 0; n < resultStringArr.length-1; n++) {

grpElement.add(new Option(resultStringArr[n],resultStringArr[n]));

}
grpElement.disabled = false;

result string will be in this form: docid=abc,docid2=bcd,
so here docid i want to put as value and display name in the dropdown as abc

from the code so resultStringArr = resultString.split(",");
i am able to split the line and now i am getting in the drop down as docid=abc next value as docid2=bcd
so i want to further split this into docid and abc so that docid will be the value and display name will be abc.

Can any one provide me code for this .



still i am getting null value by the use of req.getParameterValues("");
16 years ago
JSP
i am soory but i am not that good. so if you can place the code it will be better to understand that.
16 years ago
JSP
sorry but i am using yes or no too
in the code

my mistake to put the worng code
but this is giving me null value only
16 years ago
JSP
can we use this method in jsps.
It will retrun be some array of values so the condition which i am using wont work for this....
16 years ago
JSP
How to get radio button value which is selected by the use of
request.getParameter();
I am getting null value here.
Below is my code for radio button:
<tr><td><p>Base Component: </p></td> <td><table cellspacing="0" cellpadding="0">
<input id=" " name="BaseOption" value="" type="radio" checked='checked' /><label for="no"> No</label>
<input id=" " name="BaseOption" value=" " type="radio" /><label for="yes">Yes</label>
</table></td> </tr>

i m retrieving the value which is clicked by:

if(request.getParameter("base") != null) {
if(request.getParameter("base").equals("Yes")) {
out.println("Radio button yes was selected.<BR>");
}
else {
if(request.getParameter("base").equals("No")){
out.println("Radio button no was selected.<BR>");}
}
}

here i m getting null value
request.getParameter("base") is giving me null value. Please let me know how to get radio button value
16 years ago
JSP
Hi
I am workingon next and previous buttons.
I know the document which i have clicked by putting it in jsp parameter. Now i need to write javascript function to show the previous and next document by click of next and previous tab.

Can anyone tell how can i use jsp parameter in javascript
Hi ,
i am trying to retrive the first child node and want to put in Map. but its throwing me null pointer exception. How to get only the first child of the xml file.
Below is my code:

if (reqNode != null) {
Node nodeList1 = reqNode.getFirstChild();

if (nodeList1 != null) leftFrstMap.put(nodeList1.getAttributes().getNamedItem("label").getNodeValue(), nodeList1.getAttributes().getNamedItem("href").getNodeValue());
}
Hi i am crreating a list of document and when i will click any of the document then it will open its content.
Now i want "Next" hyperlink on the page so that the document which is at next will get navigated and "prevoius" link s so that if the document which is previously opened will get open.

If the document is first one then it sud not show me the previous link and i am at last document then it should not show me the next link.

my code to create doc list... its a jsp code
<option label="<%=element4.getKey()%>" value=" <%="edit_Amol.jsp?path="+element4.getValue()%>&val=<%="edit_Amol.jsp?path="+element4.getKey()%>"><%=element4.getKey()%></option>


now here i have previous next option:

<p>< <a class="" href=" Previous </a> | <a href="component_List.jsp">Component List</a> | <a href="javascript://">Next </a>></p>



Not getting any clue how to do this.
please help me out.
Hi,
My requirement is to open the doc at server side in MSoffice only. Basically wht i am trying to achieve over here is to launch MSOffice at the cleint side frm my appliaction.
I am wroking in Content mangagemenet. So once the doc had been opened i need to save back changes which user had made to the server also. Tht will be later requirement. WE are using XA which is MSoffice plugin to open xml doc.
So basically i have to open MSOffice.
Please let me how to do that. I dnt understand how we can just provide a link to the doc and let user to decide to open tht.
do you any remedy for that . Wht else i can use so as to open a document in the server to the client side.
Is there any other method in java script which will open word document.

Intead of ActiveX Control wht i can use?
Thanks the script works fine in IE but it wont work in FireFox.

Its showing me this error:

ActiveXObject is not defined
var word=new ActiveXObject('Word.Application');
Could you please provide me the solution for this.
Hi thanks for the quick replay but my problem is i have to launch the MSoffice plugin XA which is xml editor. But it will lauch in similar way as MSoffice doc document. So here wht we are trying to do is we will let clients to open the doc and edit and it will get save in server itself.
Here is my code which will open MSWord document through java script.

In IE it works fine but in Mozilla firefox its throwing me some error like ActiveX object is not defined.


<script language="JAVASCRIPT" type="TEXT/JAVASCRIPT">



function Comp_action()
{ var url = document.Actiontab.selectcomp.options[document.Actiontab.selectcomp.selectedIndex].value

if (url=="E")
{ alert("hello")

var word=new ActiveXObject('Word.Application');
var docText;
var obj;
word.Visible = true;
// String abc="";
obj= word.Documents.Open("C:\\A.xml");

alert("hello2")

}//if
else { } //else


}


</SCRIPT>

Please help to open MSWord doc threw Firefox also. Is Mozilla doesnt support Active Xobject.