How do you assign object properties?

Answer Posted / m_xyz

var obj=new Object();
obj["age"]=18; or obj.age=18

Is This Answer Correct ?    19 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Where is javascript used most?

475


Is it possible to do 301 redirects in javascript ?

486


How generic objects can be created?

482


How to access an external javascript file that is stored externally and not embedded?

603


Why is javascript hoisting?

456






What is Number object in JavaScript?

565


Is there an ide for javascript?

466


What is var and let in javascript?

494


What would you use javascript for?

491


What is the difference between ‘let’ and ‘const’?

557


What are the different objects used in javascripts?

483


How can you to add javascript to a page when performing an asynchronous postback?

486


What is the difference between local storage & session storage?

477


What is a fixed-width table and its advantages?

494


How do you trim in javascript?

494