label caption

Dec 31, 2010 at 3:16am
I am learning now visual c++ and I try to display two variables in the same label but it seems that I don't know how to do it. Here is the code thet works and shows me one variable and works
 
 lblresult->Text = String::Format("The n term of Fibonacci's string is: {0} ",f); 

And the one that doesn't work is:
 
 lblresult->Text = String::Format("The n term of Fibonacci's string is: {0} ",f, n); 
Last edited on Dec 31, 2010 at 3:17am
Jan 1, 2011 at 6:45am
Hi,

I asssume you are using .net, Im unable to test but i think what you need is

 
    lblresult->Text = String::Format("The n term of Fibonacci's string is: {0} {1} ",f,n);


hope this helps
Shredded
Topic archived. No new replies allowed.