|
How to enter elements of a matrix in textbox in order to use them in program?
|
|
|
|
|
More information would be needed to produce a useful response.
|
|
|
|
|
I have a textbox and I want to enter here for example 4,2,3,1 and then convert this numbers in a matrix which I can use in the future
|
|
|
|
|
Well you'll need to create some form of matrix class or use an array, then you can use the Lines property of the textbox for the rows of the matrix and for each row use the string.Split method to split it where there is a comma, then you need to put this into the array / class.
Ed
|
|
|
|
|
Hi,
I have this strange problem in my Visual Studio 2003 IDE, the Find function is not working. Pressing Ctrl+F or even choosing Quick Find from the menu bar does not show the "Find" dialog box. Did anybody encounterd this problem before? I already re-installed Visual Studio but I'm having the same problem. For other applications (e.g. MS Word, Acrobat Reader, etc.) it is working fine. Please help.
tia,
Lupin...
|
|
|
|
|
|
Hello,
I was looking at the log files for IIS, and want to display them in a windows form using c#. I already know how to just display them inside a textbox, but the content is not display in a friendly manner.
what i need help with, is displaying each section or part before the comma in its own textbox or control.
193.1*.7*.*, WebUser, 3/28/2006, 0:00:04, MSFTPSVC1, SERVER, 1*.1*.1.1*, 0, 0, 0, 331, 0, [57]USER, WebUser, -,
as you can see the log file is comma delimited...
i hope you understand my question...
thanks
The Devil Lives in all of us, It's up to you to let HIM/HER out!!!!!
|
|
|
|
|
A good started could be string[] logFields = logLine.Split(',');
--------
"I say no to drugs, but they don't listen."
- Marilyn Manson
|
|
|
|
|
Michel Prévost wrote: A good started could be string[] logFields = logLine.Split(',');
this is what i have showing in a text box...
how will your line fit here...
private void btnOpenFile_Click(object sender, EventArgs e)
{
OpenFileDialog dlg = new OpenFileDialog();
dlg.Title = "Open File";
dlg.InitialDirectory = @"c:\";
dlg.Filter = "Text Files (*.txt) | *.txt |Log Files (*.log) | *.log | All Files (*.*) | *.*";
if (dlg.ShowDialog() == DialogResult.OK)
{
StreamReader sr = File.OpenText(dlg.FileName);
string s = sr.ReadLine();
StringBuilder sb = new StringBuilder();
while (s != null)
{
sb.Append(s);
s = sr.ReadLine();
}
sr.Close();
txtContent.Text = sb.ToString();
}
The Devil Lives in all of us, It's up to you to let HIM/HER out!!!!!
|
|
|
|
|
Hi.I need to enter a list of coefficients divided by semicolon in a textbox and convert this list to an array of doubles.Anybody has any idea how this can be done?
Best regards
|
|
|
|
|
string stringList = "2.1;3.4;0.9;-0.124";
string[] splitted = stringList.Split(';');
double[] doubleList = new double[splitted.Length];
for (int i = 0; i < splitted.Length; i++)
doubleList[i] = Convert.ToDouble(splitted[i]);
Some errorhandling should also be added.
|
|
|
|
|
Hi
I have a problem that realy brings me down. I'm using the Microsoft.Ink SDK in a usercontrol project. Here i implement some functions and push the .dll file in an object tag to a asp.net site. In javascript i call the inner functions of the .dll and get a 64BitString that i save in a hidden field on the asp.net Site.
From the 64BitString i create an .gif Image and save this file in the filesystem. I need the .gif in 300 x 300 px but the file that i got have the dimensions of the ink. When i draw just a point of 2 x 2 px the .gif file got the same size.
How can i get a .gif file that got the exactly dimensions of the box i'm painting in?
My Control where i can paint something got the size of 300 x 300 px. I need exactly that as gif file.
Please help..
Best Regards
|
|
|
|
|
Hi there.
Many of you will be familiar with Outlook 2003.
I like how it looks and it made me think how does one do something similar to that. For instance on the lower left we have something (I don´t know what it is called but it is similar to TabPage) that can be pressed, Mail, Calendar, Contacts and Tasks. When one presses these a window to the right opens. How does one do this? What are the tabs/something called on the lower left?
Any information is greatly valued.
Thanks,
FJ
|
|
|
|
|
There are two Outlook Bar implementations here on CodeProject but both aren't on 2003 visual standards. You can find them here[^] and here[^].
Other than those you could buy something. There are many different commercial UI components on the market. Ask Google for Infragestics, Syncfusion, Developer Express...
|
|
|
|
|
Thanks a lot for your help. Have a nice day
FJ
|
|
|
|
|
Hello naglbitur,
If you are looking for a control suite that will make implementing an Outlook 2003 look and feel easy, please take a look at ComponentOne's Menus and ToolBars for .NET. It has an outlook style toolbar, standard toolbar, tab page, context menu, and a docking component that allows you to make any of them dock and float. You can also host other controls in the docking component. For more information, please click Here[^].
Suelinda W
Customer Engagement, ComponentOne LLC
|
|
|
|
|
hi all,
i had created a windows service and added a projectinstaller .then in the afterinstall event i am trying to start it using serviceController it installs succesfully but it is not started and i get the following exception
:System.InvalidOperationException: Cannot start service Service1 on computer '.'. ---> System.ComponentModel.Win32Exception: The service cannot be started, either because it is disabled or because it has no enabled devices associated with it
--- End of inner exception stack trace ---
at System.ServiceProcess.ServiceController.Start(String[] args)
at System.ServiceProcess.ServiceController.Start()
at TestWindowsService.ProjectInstaller.serviceInstaller1_AfterUninstall(Object sender, InstallEventArgs e)
and now if unsinstall it starts it seems afterinstall event is called in both after install and after uninstall.how can i make this service self starting i hadn't added any extra code(except in the afterinstallevent) in the windows service.
ServiceController sc = new ServiceController("Service1");
sc.Start();
sc.Close();
i am using the windows service template.
thanks in advance.
Rakesh
|
|
|
|
|
Have you checked whether the service starts up correctly when doing it manually via control panel?
|
|
|
|
|
Hi robert,
yes, i checked and it was starting perfectly.after being installed with installutil.any idea what is causing the problem.thanks in Advance.
Rakesh
|
|
|
|
|
I made a user control class and added a property called "KeyboardColor" of type string to it. Currently the choices are black and white and the class will handle both, and if something else was entered post a message back saying black and white are acceptable values, then default to white.
The property can be set design time from the control's property tab, or run time with the usual control.property = "value" method.
Is there a way to make the property appear as an LOV in the property tab and/or the intellisense?
|
|
|
|
|
Change the type of the property from string to something different.
If you really want only black and white then define an enum like this
public enum BOW {
Black,
White
}
Then set the return type of the property to BOW.
If you want to support all possible colors you could also set the type of the control to Color. This way the designer would show the same color picker gui as with the default ones (ForeColor/BackColor).
|
|
|
|
|
Thanks a lot!
Took a little time to figure out how to use an enum, but it works great.
|
|
|
|
|
Hello!
When disabling a treeview control, its background isn't set to gray automatically (in contrast to the listview control).
I want to set the color myself now (using the BackColor property of the treeview), but I don't know the color value of the "disabled" color. Any idea where to get it from?
I of course don't want to hardcode the value, it should be dependent on the current system colors...
Best regards
Dominik
_outp(0x64, 0xAD);
and
__asm mov al, 0xAD __asm out 0x64, al
do the same... but what do they do??
(doesn't work on NT)
|
|
|
|
|
I'm not sure but shouldn't this simply be SystemColors.Control?
|
|
|
|
|
Hello, may be some of you could help me. I have a winform with FormBorderStyle asigned to None (I need it in that way), and an AXWebBrowser with Dock asigned to Fill. My problem is that the MouseEnter event for the winform only work if I have a part of it visible, but in this case I must have the webbroser filling all the winform, so the event MouseEnter never work. And the webbrowser doen't have a MouseEnter event, so I can't call that event too. I need the event for enter and leaving.
I try:
((Control)this.browser).MouseEnter += new System.EventHandler(this.AlertWindow_MouseEnter);
But doesn't work !!!
Can any of your give an example of how can I implement my own mouse enter event jobs?
Any ideas??
Thanks a lot.
|
|
|
|