You need to sign in to do that
Don't have an account?

ajax remote action error. please help
here i am confusing how to add text box value at 'where' condition in the ajax query. This is not working. please help.
<apex:page id="pageId"> <apex:form > <script src="/soap/ajax/30.0/connection.js" type="text/javascript"></script> <script> var text11; function jaff(myid) { var text11=myid.value; alert(text11); } function show() { <!-- ***************************** Check this below line ******************* --> var query="Select Name, Industry From Account where industry= "+text11; sforce.connection.sessionId = "{!$Api.Session_ID}"; var queryResult = sforce.connection.query(query); if (queryResult.size > 0) { var output = ""; var records = queryResult.getArray('records'); var result=''; for (var i = 0; i <records.length; i++) { var account = records[i]; result += account.Name ; } } document.getElementById('{!$Component.output}').innerHTML=result; document.getElementById('{!$Component.output1}').value=result; // i u remove the above line then error coming } </script> <apex:inputtext id="j1" onchange="jaff(this)" /><br/> <apex:commandButton value="click" onclick="show()" rerender="output" /> <apex:outputLabel id="output"/> </apex:form> </apex:page>
All Answers
If it will not solve your problem please have a look at this
https://developer.salesforce.com/forums/?id=906F000000098RdIAI
AND
http://salesforce.stackexchange.com/questions/24093/jquery-not-getting-data-from-outputtext-field