|
|
hi all.
i have written a Bwroser Help Object using visual c# 2005.
Now how i install and deploy it on my client machine.
many of my client machine has not dot net framework.
should dotnetframwork be installed to run this small dll?
sepel
|
|
|
|
|
Hello everyone,
Lately, I'm concerned about internet protocols and had this big question of how such proxy avoidance websites work?? Can I create my own?? How??
Any good articles/hints would be appreciated as I have no idea where to start from..
Thank you guys
Smile: A curve that can set a lot of things straight!
(\ /)
(O.o)
(><)
|
|
|
|
|
how to return arrays from functions?
if the array is created inthe function itself.
|
|
|
|
|
By defining the return type as array and return it, no difference from other data type.
public string[] GetStrings()
{
string[] arrayOfString;
// define array, do stuffs
return arrayOfString;
}
|
|
|
|
|
Strictly speaking, you don't return the array itself, but the reference to it, as with any object.
public int[] GimmeSomeInts() {
int[] result;
result = new int[] { 1,2,3,92849832 };
return result;
}
Experience is the sum of all the mistakes you have done.
|
|
|
|
|
How do i add a list of items for an embedded windows media player to play.
threw website/you're own movies. Or what is the code to link a button to set the media player to read the next video, or add a new url to the player?
If anyone can show me an article on how i can do this. Be most appreciated.
Also i've made my program so it's a fixed tool window, how can i make a button in my menu to be able to move it. It won't let me click/drag as a fixed tool window, and i don't want it to be a fixed 3d border.
Thanks in advance.
|
|
|
|
|
hi all ,
i want to create an app to change or remove password of my user in pc .
when my pc load , for some user that we created password , we have to enter the password (sometimes we forgot this password ) , in any case with using c# how can i do it ?
thanx a lot for any guide .
s_mostafa_h
|
|
|
|
|
hi
My aim is to ping a socket....i want this to be done from one side i mean the application which is sending the ping signal(byte)....should not take response from the client.......
i tried with socket.send ...it doesnt ensures that bytes are received at client side or not
then i tried with socket.sendto....same thing
so if any one knows how to do this please let me know............
regards
sindhu tiwari
its me sid
|
|
|
|
|
|
Hello friends,
I am developing an C#.NET application and I want that whenever an exe is running then on the same system that exe could not run simultaneously. when i closed that running exe then it then i will able to run it again...
Means when exe is running then that same exe never run on the same system
|
|
|
|
|
hi write this code in program.cs if the application is already open the if part will execute ....and if not else part is execute...............hope this will solve ur problem..
if (Process.GetProcessesByName(Process.GetCurrentProcess().ProcessName).Length > 1 )
{
MessageBox.Show("The application is already launched...","Error", MessageBoxButtons.OK, MessageBoxIcon.Stop);
return;
}
else
{
// the things in program.cs
}
regards
sindhu tiwari
its me sid
|
|
|
|
|
thank's alot
i look for this too
|
|
|
|
|
|
How is that "more reliable"?
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
If the user renames your executable file, you won't be able to detect it in current processes.
|
|
|
|
|
Giorgi Dalakishvili wrote: If the user renames your executable file
You could always make the executable check if its original name is the same one it is using. If it detects user renamed it, then don't run.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|
|
hi
I created a project in c#.net using MySql as database. I created a setup and installed it into another client machine but at the time of installation i need to check whether MySql database exist in the client machine.Is this possible in C#.net? Plz Help Me
Thanks in Advance
Smithakrishnan
|
|
|
|
|
Do you want to detect if MySQL Server is installed?
The code below is straight from Microsoft[^] - I've just altered the name of the service! Adapt it to suit your needs. (You need to add a reference in your project to System.ServiceProcess)
using System;
using System.Collections.Generic;
using System.Text;
using System.ServiceProcess;
namespace ConsoleApplication1
{
class Program
{
static void Main()
{
string myServiceName = "MySQL";
string status;
Console.WriteLine("Service: " + myServiceName);
ServiceController mySC = new ServiceController(myServiceName);
try
{
status = mySC.Status.ToString();
}
catch (Exception ex)
{
Console.WriteLine("Service not found. It is probably not installed. [exception=" + ex.Message + "]");
Console.ReadLine();
return;
}
Console.WriteLine("Service status : " + status);
if (mySC.Status.Equals(ServiceControllerStatus.Stopped) | mySC.Status.Equals(ServiceControllerStatus.StopPending))
{
try
{
Console.WriteLine("Starting the service...");
mySC.Start();
mySC.WaitForStatus(ServiceControllerStatus.Running);
Console.WriteLine("The service is now " + mySC.Status.ToString());
}
catch (Exception ex)
{
Console.WriteLine("Error in starting the service: " + ex.Message);
}
}
Console.WriteLine("Press a key to end the application...");
Console.ReadLine();
return;
}
}
}
|
|
|
|
|
After a little experimentation trying to control a service I found that
myServiceController.Start(); and
myServiceController.Stop(); both fail under Vista because UAC insists it's done with true Administrator privileges. To make them work you need to add an Application Manifest File and alter the level attribute of the requestedExecutionLevel tag to requireAdministrator . When the application is executed, you'll then get the annoying UAC Cancel/Allow dialog.
|
|
|
|
|
Just when you think you've seen everything...
public SearchCriteria() : this(2000, 1) {}
...this is a default constructor for the SearchCriteria object... but what is that stuff after it... I can't find any documentation of this feature because searching for colon operator only gives me articles about inheritance of classes and interfaces. What are the implications of this construct, and what does it do...
There is another constructor that takes two integers. Is this the same as calling that one with 2000 and 1 as default values? If it is, I'm confused as to the purpose of this notation, when you could just as easily initialize those values "normally" or call the other constructor within this one, or something. There must be a reason for this colon thingy?
|
|
|
|
|
Jasmine2501 wrote: Is this the same as calling that one with 2000 and 1 as default values?
Well, not default values but actual values, but, yes.
Jasmine2501 wrote: or call the other constructor within this one
No, you can't call another constructor in the code, that's the purpose of the special syntax.
Experience is the sum of all the mistakes you have done.
|
|
|
|
|
|
It calls the constructor in the current class that has two int parameters and initializes them with the values 2000 and 1. You can fall through these constructors many times as in the following example:
public SearchCriteria() : this(2000, 1) {}
public SearchCriteria(int value, int otherValue) : this(value, otherValue, 20) {}
public SearchCriteria(int value, int otherValue, int finalValue)
{
_value = value;
_otherValue = otherValue;
_finalValue = finalValue;
}
|
|
|
|
|
I should also point out that this is covered in books such as C# Step-by-Step (Microsoft Press). i.e. it is a very basic concept in the language that perhaps you might want to revise.
|
|
|
|