Click here to Skip to main content
15,888,579 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
this is the source code what am tried

XML
<select  id="Select1" name="shortcut" class="sl"; style="margin-left:10px">
   <option></option>
     <option onclick="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">Belarusian</option>
     <option onclick="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">Bulgarian</option>
     <option onclick="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">German</option>
     <option onclick="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">English</option>
 </select>


when am executed this query it will show the error message of invalid argument...

help me to solve this.....
Posted
Comments
Sandeep Mewara 14-May-12 5:10am    
Ok. I find this question as a MULTIPLE reposts. Why so? Please avoid it.

1 solution

hello,

select does not has an event for onclick, try onchange like this
HTML
<select id="Select1" name="shortcut" class="sl" style="margin-left: 10px">
       <option selected="selected">Select Language</option>
       <option onchange="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">
           Belarusian</option>
       <option onchange="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">
           Bulgarian</option>
       <option onchange="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">
           German</option>
       <option onchange="window.open('multi_language.htm','Multi Language','width=500,height=400,left=250,top=100,screenX=100,screenY=100')">
           English</option>
   </select>

hope this will help you.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900