+ 2
visual studio array
hello, How to the label showed the 1 if we input the name of one the label index will show the 1 and if input is then the label will show two and so on. thank you
30 Answers
+ 2
It seems you wish to create a program that accepts an index value and then retrieves the element at that value. But the index must start from 1, right?
int main()
{
int arr[10]={1,2,3,4,5,5,6,4,2,1};
int index = 0;
do
{
cin>>index;
cout<<"Elm "<<index<<
" - "<<arr[index-1]<<endl;
} while(index<=10 && index>0);
}
+ 2
In the text box in the middle, will you enter the Array elements?
+ 1
@mitsu
Sorry, I thought you wanted a C++ answer, as you tagged C++.
Is your input via C++ or VB?
+ 1
Now, what do you want to do? Show 1 on a mouse click? Or what? Can you please explain again?
+ 1
i see, sorry for my task 😞
+ 1
increase the index is max and button for array it’s simpan
+ 1
i mean button simpan for store array
+ 1
i’m forget to button show array 😭😭
+ 1
i upload design again sorry make you confused
+ 1
can you give me link code you made now?
+ 1
it’s ok , thank you for helping me
+ 1
it’s no problem 😊😊😊
+ 1
it’s no problemm, this so hard for me 😂 haha
+ 1
maybe i will ask you later about this . i still curious 😂 @Kinshuk
0
thank you but i mean in language visual basic , how to label show 1 if button click?
0
visual basic hehe sorry i’m use tag c++
0
i need your help, thank you for your help thank you very much 🙏🏻
0
yes show 1 on a mouse click in button and it will show in label 1 and click again it show 2 and so on
0
Ill upload the code soon.