• Amit Singh Rathaur
  • NEWBIE
  • 25 Points
  • Member since 2019

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies
I have the following in the component:
<lightning:input type="number" aura:id="input1" name="input1" value="1" required="true" />
In the controller.js I have an action that returns a value from the component controller.

I'd like to multiply this value with the number entered in "input1" and display it.

I do not seem able to read the value that is in "input1". I tried
alert('cmp.find(input1) = ', cmp.find('input1').get('v.value'));
and it shows an empty value.

thank you
 
I have the following in the component:
<lightning:input type="number" aura:id="input1" name="input1" value="1" required="true" />
In the controller.js I have an action that returns a value from the component controller.

I'd like to multiply this value with the number entered in "input1" and display it.

I do not seem able to read the value that is in "input1". I tried
alert('cmp.find(input1) = ', cmp.find('input1').get('v.value'));
and it shows an empty value.

thank you
 

Hi Forum members

 

I added a hoover to my visualforce page and the hoover appears on the mousover event of a label

 

onmouseover calls a javascript code which is following

 

    <script src="/soap/ajax/15.0/connection.js"></script>
    <script src="/soap/ajax/15.0/apex.js" type="text/javascript"></script
>

 

       function myHover()
       {  

 

             sforce.connection.sessionId = "{!$Api.Session_ID}

             var resultQuery = " Select ID,Name from ACCOUNT LIMIT 2";

              

                     try
                    {
                        result = sforce.connection.query(resultQuery);
                    }
                    catch(e)
                    {
                        alert(e);
                    }

 

 

           //Some Code to show hoover with result

 

       }

 

 

Now the problem is this code works fine in a DEVELOPER Org and shows data of above query on hoover

 

But when i run this same code in sandbox or any Trial org 

the line  sforce.connection.query(resultQuery); raise following excepion

 

 

 

 

{faultcode:'sf:INVALID_SESSION_ID', faultstring:'INVALID_SESSION_ID: Invalid Session ID found in SessionHeader: Illegal Session', detail:{UnexpectedErrorFault:{exceptionCode:'INVALID_SESSION_ID', exceptionMessage:'Invalid Session ID found in SessionHeader: Illegal Session', }, }, }

 

 

 

 

 

Please comment if someone knows the solution of this problem

 

Thanks

 

Message Edited by Nikhil on 04-07-2009 02:46 AM
  • April 07, 2009
  • Like
  • 1