|
I may be wrong, but i think it uses geos. If that is the case, no.
|
|
|
|
|
i designed a mobile application,
is this application can be run on Nokia 9110 Communicator?
thanks for help
MD_NADA
|
|
|
|
|
hi,
how do i highlight syntax in c# as soon as I open a text file which contains c# code in it into a richtextbox in windowsforms.
Don't wait to hear a word of thanks from anybody when you help them instead ask them to help three other people and ask them to continue in chain.
|
|
|
|
|
veluru krishna wrote: how do i highlight syntax in c# as soon as I open a text file which contains c# code in it into a richtextbox in windowsforms.
You might want to read up on the subject of Language Processors. Syntax highlighting is a form of language processing.
|
|
|
|
|
.NET doesn't provide such a control. Use the search function at the top to search for articles.
regards
modified 12-Sep-18 21:01pm.
|
|
|
|
|
hi,
when use the following code
SaveFileDialog dlg = new SaveFileDialog();
dlg.Filter = "Text Files|*.txt|Comma Seperated Files|*.csv|All Files|*.*";
dlg.InitialDirectory = @"C:\";
saveFileDialog1.OverwritePrompt = true;
if (dlg.ShowDialog() == DialogResult.OK)
{
using (System.IO.StreamWriter writer = new System.IO.StreamWriter(dlg.FileName))
{
writer.Write(this.richTextBox1.Text);
writer.Flush();
}
}
it saves a file but unfortunately it saves it without newline characters ie.,. I want to save my work as it is displayed in the multiline text box.can you help me please
Don't wait to hear a word of thanks from anybody when you help them instead ask them to help three other people and ask them to continue in chain.
|
|
|
|
|
Are you viewing your file with notepad.exe? RichTextBox delimits the lines with a \n instead of the windows typical \r\n , that's why some editors have troubles with it. Proper editors like NotePad++ or UltraEdit have no problems with a \n on windows.
You might do that:
writer.Write(richTextBox1.Text.Replace("\n", Environment.NewLine));
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Good day.
I would like to know if there is an API i can use to change windows service to run under LocalSystem account from a user account. Currently I am using the API below to change the service from using a LocalSystem account to a user account.
public static int ChangeService(string Name, string Password, string serviceName)
{
ManagementBaseObject inParams = null;
ManagementObject srvc = new ManagementObject("Win32_Service.Name='" + serviceName + "'");
inParams = srvc.GetMethodParameters("Change");
inParams["StartName"] = Name; //account name .\\localaccount;
// 'domain\\domainaccount' (or account@somedomain on XP and up)
inParams["StartPassword"] = Password; // password
ManagementBaseObject outParams = srvc.InvokeMethod("Change", inParams, null);
return System.Convert.ToInt32(outParams.Properties["ReturnValue"].Value);
}
But the problem now is that i cant change the service back to LocalSystem.
Many thanks in advance.
Kulile --- RSA
|
|
|
|
|
Hi all
I am using the code below to open an internet explorer window:
System.Diagnostics.Process.Start(
"iexplore.exe",
"http://www.codeproject.com"
);
It works well, but in ie7, it opens a new window every time. But i want to open a new tab instead of a new window. Is there any way to do this?
Thanks
ozgur.nevres
|
|
|
|
|
Stupid IE7, i don't like it.
Well, that doesn't work because it starts a whole new process, you want to tell the existing process to open up a new tab... i have no idea how to do that
But i shall investigate... AWAY!
|
|
|
|
|
Have you tried starting http://www.codeproject.com as a process in stead of iexplore??
System.Diagnostics.Process.Start("http://www.codeproject.com");
I haven't got IE7 installed so cannot test, i'm sorry, but maybe it's the trick
- - - --[ i love it when a plan comes together ]-- - - -
|
|
|
|
|
GREAT! It worked.
Many thanks!
And it is better than first one, cz it is using the default browser, not ie only. I changed my default browser to opera, and it opened a new tab in opera.
ozgur.nevres
|
|
|
|
|
Your problem is that you are starting a new iexplore process each time.
|
|
|
|
|
Mertli Ozgur Nevres wrote: System.Diagnostics.Process.Start(
"iexplore.exe",
As a Firefox user I tell you: Don't - do - this - EVER!
Starting the link directly is okay on windows, windows will take care of it itself.
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Hi all,
I have a problem with the ListBox Control. Let me first explain my application:
I have here a UserControl (contains list box and dataGridView) and form called AttendanceScreen (which reposibles to send data from database to UserControl). In additon, that form includes that UserControl.
So when the form loaded which contains the userControl, it will send dataSet to the userControl as data source for the listBox.
And when the user select any item from the listBox that event will be triggered by selectedValueChange. The handler of that event will be responsible about sending the value of selectedItem to the form by the Association relationship.
And my problem is located in this moment.
the excaption message said -> "NullReferenceException was unhandled by user code"
My code here:
userControl Class::
<br />
private void employeeListBox_SelectedValueChanged(object sender, EventArgs e)<br />
{<br />
if (IsReleased)<br />
{<br />
attendScreen.employeeAttendanceTriggered(int.Parse(this.employeeListBox.SelectedValue.ToString()));<br />
}<br />
}<br />
<br />
when I tested by MessageBox like
<br />
private void employeeListBox_SelectedValueChanged(object sender, EventArgs e)<br />
{<br />
if (IsReleased)<br />
{<br />
MessageBox.Show(this.employeeListBox.SelectedValue.ToString());<br />
}<br />
}<br />
<br />
it works fine. so where's the problem
*
I forgot to include that when I have tried to do everything in userControl (connecting to database and retrieve data and then displayed in dataGridView, it works fine for the dataGridView BUT all items in ListBox disappeared - no more selectedValueChange event fired)
*
Thanks in advance.
|
|
|
|
|
|
|
iam working in c# on stress testing tool,for this i have to track and record user activities performed by user after opening webpage .i need help in code form.
|
|
|
|
|
2. Be specific! Don't ask "can someone send me the code to create an application that does 'X'. Pinpoint exactly what it is you need help with.
|
|
|
|
|
I love your screen name.
Have you seen this thread? [^]
|
|
|
|
|
do you have any idea about hooks in VC?
you can track the activities of a user by using hooks. just read about how to implement hooks in c#.
regards
sAqIb
"Our scientific power has outrun our spiritual power. We have guided missiles and misguided men."
Dr. Martin Luther King Jr.
|
|
|
|
|
Hello
Let's say I have two forms, form1 and form2. Form1 have only one button and now each time I click this button form2 should show in the front of form1.
Well whats the best practice in doing such thing ? I mean I can create
one instance of form2 in the form1's constructor and then use only
Show() and Hide() methods of form2 or create new instance of form2
each time i click button on form1.
I'm not sure if my problem is clear enough . Let me now if you need more details.
greetings
tommy
|
|
|
|
|
It all depends on what you want to do with your form.
Check Form.BringToFront() method
|
|
|
|
|
Can't you show it as modal?
|
|
|
|
|
Hi...
I want to read a string from a dll & i want to print it in a rich text box on windows form.
How can i do this...?
How i can define a function which will return a string in dll file so that i can call that function from my form class & get the string to display on form...?
Thanks,
Vinay
|
|
|
|