Announcement

Collapse
No announcement yet.

C# (or any .Net language) example using a custom list (CL)

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • C# (or any .Net language) example using a custom list (CL)

    I have a skin with the following definition:

    Code:
    /, IL, LIST, SelImg, UnselImg, EndImg, LimitMode, Drag, MaxSpeed
    IL,CL,transparent.bmp,sel.bmp,end.bmp,0,50,60
    
    /, S, x, y, w, h, fore R;RGB, G, B,  back R;RGB, G, B,  folder R;RGB, G, B,  file R;RGB, G, B, selected R;RGB, G, B, select R;RGB, G, B, trs, font pt;FONT, font name
    SC,158,208,474,236,255,255,255,3,80,40,0,0,0,255,128,0,TRUE,20,"Lucida Sans Unicode"
    I'm having trouble figuring out how, in C#, to get each line into the list with an icon at the beginning of each line.

    Does anyone have a C# example (or any .Net language or even VB6) of how to load the list and then how to determine which item was selected by the user?

    Regards,
    Jim

  • #2
    try to contact the user pierrotm777
    RR-Skin: BMW OpenBM Skin for E39 [never ending progress :-(]
    RR-Plugin: IBusCommunicatoRR new Updates

    Comment


    • #3
      Code:
                      case "rr_translator_fromtolanguage":
                          SDK.Execute("MENU;RRTranslator_Languages.skin||CLCLEAR;ALL");
                          if (File.Exists(DPath + "Languages.txt")) {
                              string[]  sArray = File.ReadAllLines(DPath + "Languages.txt");
                              for (int p = 0; p <= sArray.GetUpperBound(0); p++)
                              {
                                  SDK.Execute("CLADD;" + sArray[p]);
                                  if (File.Exists(DPath + "Languages\\" + sArray[p] + "\\" + sArray[p] + ".gif"))
                                  {
                                      SDK.Execute("CLSETIMG;" + (p + 1) + ";" + DPath + "Languages\\" + sArray[p] + "\\" + sArray[p] + ".gif");
                                  }
                                  else
                                  {
                                      SDK.Execute("CLSETIMG;" + (p + 1) + ";" + DPath + "Languages\\Error.gif");
                                  }
                              }
      
                              //selectionne la ligne du language actuel
                              SDK.Execute("CLFIND;" + INI.ReadString("RRTranslator", "Language", ""));
      	                                        } else {
                              SDK.ErrScrn("!! Info !!", DPath  + "Languages.txt file is not found !!!", "");
                          }
                          result = ProcessCommandResults.CommandProcessedStayOnScreen;
                          break;

      Comment

      Working...
      X