Line 71:                                           
 

Source File: C:\Inetpub\wwwroot\iDesk\popaccountNew.aspx    Line: 69


The code on the cs page for the method is:
private void cboArenas_SelectedIndexChanged(object sender, System.EventArgs e)
            {
                  string strArenaCode = "";            
                  
                  strArenaCode = cboArenas.SelectedItem.Value;                        
                  
                  strArenaCode = strArenaCode.Replace("0","");                  
            
                  FillContriesComboBox(strArenaCode,"",false);                  
                  FillBuildingGroupComboBox(strArenaCode,"","",false);                                    
                  FillMABUComboBox(strArenaCode,"","","","");
                  FillMASubBUComboBox(strArenaCode,"","","","");
                  FillBUComboBox(strArenaCode,"","","","","","");                  
            }

Any help will be appreciated
thanks
Paul

Question : Compiler error CS0122 ...inaccessible due to its protection level

I have built an ASP.NET app and am receiving this error.
The page is trying to open and show a series of dropdown boxes for a User to make selection criteria but I get this error message:


Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: CS0122: 'iDesk.popAccountNew.cboArenas_SelectedIndexChanged(object, System.EventArgs)' is inaccessible due to its protection level

Source Error:

 

Line 67:                                                 


Line 68:                                                       Arenas:label>D>
Line 69:                                                 
ist id="cboArenas" Runat="server" Width="75%" AutoPostBack="True" CssClass="txtSmall" OnSelectedIndexChanged="cboArenas_SelectedIndexChanged">downlist></TD>
Line 70:                                           

Answer : Compiler error CS0122 ...inaccessible due to its protection level

I'm not sure what the code in these look like:

FillContriesComboBox(strArenaCode,"",false);              
               FillBuildingGroupComboBox(strArenaCode,"","",false);                              
               FillMABUComboBox(strArenaCode,"","","","");
               FillMASubBUComboBox(strArenaCode,"","","","");
               FillBUComboBox(strArenaCode,"","","","","","");              

But if you are trying to access the collection object to add things to it, then you will get this message (ie. if you are trying to access System.Collections).  

If you want to use the System.Collections.List class then you have to import the name space at the top of your code before using it.

ex.  Imports System.Collections
      Imports System.Collections.List


Cheers,

Leo
Random Solutions  
 
programming4us programming4us