witam serdecznie , mam tu taki mały wycinek kodu , proszę o pomoc , chodzi o to aby po wklejeniu tego kodu do innego już istniejącego pojawił mi się odpowiedni tekst na ekranie , próbowałem wklejać ten fragment kodu do innego kodu kompilowało bez problemu ale tekst się nie pojawiał - jak to pozmieniać ? proszę o pomoc
string gs_140 = "---_";
void DrawLogo() {
string l_name_0 = gs_140 + "L_1";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 13);
}
ObjectSetText(l_name_0, "--Ustawienia przygotowane dla pary-- ", 10, "Arial",DarkTurquoise );
l_name_0 = gs_140 + "L_2";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 35);
}
ObjectSetText(l_name_0, "--EUR JPY TF M5--", 10, "Arial", DarkTurquoise);
l_name_0 = gs_140 + "L_3";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 60);
}
ObjectSetText(l_name_0, "------M-7 V1-----", 10, "Arial", White);
l_name_0 = gs_140 + "L_4";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 40);
}
ObjectSetText(l_name_0, "_____________________", 12, "Arial", Yellow);
l_name_0 = gs_140 + "L_5";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 65);
}
ObjectSetText(l_name_0, "_____________________", 12, "Arial", Yellow);
Proszę o pomoc - mała zmiana w kodzie chodzi o tekst
- investsoft.pl
- Stały bywalec
- Posty: 35
- Rejestracja: 30 sie 2013, 11:38
Re: Proszę o pomoc - mała zmiana w kodzie chodzi o tekst
Wystarczy wkleić bezpośrednio np. w funkcji init():
albo nieczego nie zmieniać tylko w start lub init wywołać funkcje:
Kod: Zaznacz cały
string gs_140 = "---_";
string l_name_0 = gs_140 + "L_1";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 13);
}
ObjectSetText(l_name_0, "--Ustawienia przygotowane dla pary-- ", 10, "Arial",DarkTurquoise );
l_name_0 = gs_140 + "L_2";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 35);
}
ObjectSetText(l_name_0, "--EUR JPY TF M5--", 10, "Arial", DarkTurquoise);
l_name_0 = gs_140 + "L_3";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 60);
}
ObjectSetText(l_name_0, "------M-7 V1-----", 10, "Arial", White);
l_name_0 = gs_140 + "L_4";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 40);
}
ObjectSetText(l_name_0, "_____________________", 12, "Arial", Yellow);
l_name_0 = gs_140 + "L_5";
if (ObjectFind(l_name_0) == -1) {
ObjectCreate(l_name_0, OBJ_LABEL, 0, 0, 0);
ObjectSet(l_name_0, OBJPROP_CORNER, 0);
ObjectSet(l_name_0, OBJPROP_XDISTANCE, 10);
ObjectSet(l_name_0, OBJPROP_YDISTANCE, 65);
}
ObjectSetText(l_name_0, "_____________________", 12, "Arial", Yellow);
Kod: Zaznacz cały
DrawLogo();
Re: Proszę o pomoc - mała zmiana w kodzie chodzi o tekst
ok dzięki wielkie - zagrało pozdr