Ok, got it :) Thanks.
There is no spoon.
Ok, got it :) Thanks.
There is no spoon.
Something like that but for WinForms...
There is no spoon.
Yes, that's it, in a recursive way and for WinForms.
There is no spoon.
modified on Thursday, March 12, 2009 10:41 AM
Hello gurus, I have a simple question for C# masters concerning controls. I have a series of label with a formated name. In a loop, I want to recover a pointer on the control (a label) by giving its name as a string. for example: Label lbl = null; string lblName = ""; for (int i=0; i<5; i++) { lblName = "lblL" + i.ToString(); // lblName will contain "lblL0", "lblL1" etc. // here is what I'm looking for... lbl = ???; // the label is supposed to point on the label with the built name contained in the variable lblName. // now the lbl variable points on the right control with name given by the variable lblName lbl.Text = i.ToString(); }
How to make the control pointing to the right one given its name? I hope you understood my question in my poor english. Best regards. Fred.
There is no spoon.
The casting gave me a null
vaue. That's really odd.
There is no spoon.
I'm getting a null
value.
There is no spoon.
Hello gurus, I have a context menu shared by 3 controls. Those controls are simply panels that have the same context menu. I would like to know how I it is possible to know which panel is the owner of the context menu and called the click event. I thought the sender
parameter of the click event was the owner of the context menu but it is not. So, how can I know the owner of the context menu??? I hope my question was clear. Thanks in advance for your answers. Best regards. Fred.
There is no spoon.
Ok, it works fine :) It's not the same order as the web tab, but it's better than doing no sort. :) Thanks.
There is no spoon.
Yes, really good question. My algorithm described above, is working but the colors are not sorted the right way.
There is no spoon.
And how can you do that? I have used the following simple algorithm: - I get KnownColor
enum values names as a string array. - I search for the text and get the index in the value names as a start point - in the loop that draws my curves (using ZedGraph) I go to then next index of the string array by incrementing it if the index goes too far, I switch to 0 to go to the begining of the array, I get the name of the color, convert it to its Color
value Of course, KnownColor
is not ordered the same way as the "web" tab in the color picker of Visual Studio, thus, I'd like to know how it is sorted. But the colors of the curves are changing.
There is no spoon.
Ok, I have it. Thanks guys :) Fred.
There is no spoon.
When you look at the color picker, you have 3 tabs, one contains the names of the colors ("Web" tab). When the user selects Red, I'd like to programatically go to the next color, that is Brown, FireBrick etc. Fred.
There is no spoon.
Hello gurus, I have a problem to solve. I'm using a set of standard named colors. When the user selects a given color lets say Red
, I'd like to know how I can select programmatically the next colors to Red
, that is Brown
, FireBrick
, etc. The named colors are from the panel "Web" of the color selector. I hope my question is clear enough. Best regards. Fred.
There is no spoon.
Ok that works great :) Thanks! :-D
There is no spoon.
Hi gurus, I would like to know how it is possible to insert in a combo box the text values of an enumeration object? For example, consider the SymbolType
enum object from ZedGraph. I would like to browse the enumeration values and add them in a combo box in order to give to the user the possibility to select the symbol for the curve. I hope my question is clear enough. Best regards. Fred.
There is no spoon.
Hi gurus, I'd like to know how can I get the decimal separator of the current host? How can I know if the decimal separator is a point or a coma? Thanks in advance. Fred.
There is no spoon.
Hi, As I said, the data are already in a DataSet
loaded in memory from a CSV file and not in a database. Best regards. Fred.
There is no spoon.
Okay, Sorry for my poor english. I have sucessfully imported a CSV file into a DataSet
. I need to execute an SQL statement using COUNT
, GROUP BY
and ORDER BY
. The request is done and works fine. I need to run it in C#. While the data remain in a DataSet
, I would like to know how I can execute the SQL statement on this DataSet? Best regards. Fred.
There is no spoon.
Hello gurus, I have a request for you. I have imported a flat file (delimited text file) into a DataTable
from a DataSet
. I wish to run an SQL statement such as "SELECT toto as X, count(titi) as Y from MY_TABLE GROUP BY X, ORDER BY X"
where 'toto' and 'titi' are field from the MY_TABLE. How is it possible to do that in C#? I hope my question is clear. If not, let me know, I'll try to explain in better way. Best regards. Fred.
There is no spoon.
Hello gurus, I have some linking problem with Visual Studio 2005 installed on an Windows XP Professional x64 Edition with Platform SDK for Windows Server 2003 R2 (march 2006). I have the following linking errors: 1>xxx.obj : error LNK2019: unresolved external symbol __imp__wstat64i32 referenced in function xxx 1>xxx.obj : error LNK2019: unresolved external symbol __imp__stat64i32 referenced in function xxx 1>xxx.obj : error LNK2019: unresolved external symbol __imp__wfindfirst64i32 referenced in function xxx 1>xxx.obj : error LNK2019: unresolved external symbol __imp__findfirst64i32 referenced in function xxx 1>xxx.obj : error LNK2019: unresolved external symbol __imp__wfindnext64i32 referenced in function xxx 1>xxx.obj : error LNK2019: unresolved external symbol __imp__findnext64i32 referenced in function xxx I can see these unresolved references are declared in stat.h (_stat) and io.h (findfirst/findnext) and should be linked with the CRT but I don't find the correct lib to link with. Does any body has a clue to solve this problem? Best regards. Fred.
There is no spoon.