4
Answers

Missing directory reference in List<>

sathish

sathish

8y
344
1
In the below source I am getting error as missing directory reference for the string country in list<br /><br /><br /><p><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">private</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2">MultiSelectList</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> GetCountries(</font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">string</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">[] selectedValues)</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> <p> {</p> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2">List</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">&lt;<span style="background-color: yellow;">Country</span>&gt; Countries = </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2">List</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">&lt;<span style="background-color: yellow;">Country</span>&gt;()</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> <p> </p> <p> {</p> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> Country() { ID = 1, Name= </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"United States"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> },</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> Country() { ID = 2, Name= </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"Canada"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> },</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> Country() { ID = 3, Name= </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"UK"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> },</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> Country() { ID = 4, Name= </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"China"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> },</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> Country() { ID = 5, Name= </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"Japan"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> }</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> <p> };</p> </font></font><p><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">return</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2"><font color="#0000ff" face="Consolas" size="2">new</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2"> </font></font><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2"><font color="#2b91af" face="Consolas" size="2">MultiSelectList</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">(Countries, </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"ID"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">, </font></font><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2"><font color="#a31515" face="Consolas" size="2">"Name"</font></font></font><font face="Consolas" size="2"><font face="Consolas" size="2">, selectedValues);</font></font></p><font face="Consolas" size="2"><font face="Consolas" size="2"> <p> }</p><p><br /></p></font><p>Thanks</p><div>Sathish&nbsp;</div><p><br /></p><p><font face="Arial" size="3"><br /></font></p></font><p><br /></p><p><br /> </p>
Answers (4)