473,396 Members | 2,004 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Accessing to some remote resource

I would like to know how to access to a machine using username and password
using C#

tnk
Aug 7 '06 #1
3 1818
tnk,

You need to be a little more specific. There are many ways to access a
machine. What exactly you are trying to access on the machine will dictate
how you go about doing it with a particular set of credentials.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Telem@co" <te********@walla.comwrote in message
news:O%****************@TK2MSFTNGP02.phx.gbl...
>I would like to know how to access to a machine using username and password
using C#

tnk

Aug 7 '06 #2
I would like to access to MSMQ to simply enumerate all private Queues.
This code
foreach(MessageQueue queue in MessageQueue.GetPrivateQueuesByMachine("Ws1"))
{

Queues.Add(queue.Path);

}

Obtain:
"The MSMQ service is not available"
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comha
scritto nel messaggio news:uM**************@TK2MSFTNGP06.phx.gbl...
tnk,

You need to be a little more specific. There are many ways to access a
machine. What exactly you are trying to access on the machine will
dictate how you go about doing it with a particular set of credentials.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Telem@co" <te********@walla.comwrote in message
news:O%****************@TK2MSFTNGP02.phx.gbl...
>>I would like to know how to access to a machine using username and
password using C#

tnk


Aug 7 '06 #3
You might want to take a look at the WindowsIdentity class. In the
documentation there is a sample on how to impersonate a user using that
class, along with code called through the P/Invoke layer.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Telem@co" <te********@walla.comwrote in message
news:O$**************@TK2MSFTNGP03.phx.gbl...
>I would like to access to MSMQ to simply enumerate all private Queues.
This code
foreach(MessageQueue queue in
MessageQueue.GetPrivateQueuesByMachine("Ws1")) {

Queues.Add(queue.Path);

}

Obtain:
"The MSMQ service is not available"
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comha
scritto nel messaggio news:uM**************@TK2MSFTNGP06.phx.gbl...
>tnk,

You need to be a little more specific. There are many ways to access
a machine. What exactly you are trying to access on the machine will
dictate how you go about doing it with a particular set of credentials.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Telem@co" <te********@walla.comwrote in message
news:O%****************@TK2MSFTNGP02.phx.gbl...
>>>I would like to know how to access to a machine using username and
password using C#

tnk



Aug 7 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Jaydeep | last post by:
Hello, I am facing a strange problem. Problem accessing remote database from ASP using COM+ server application having VB components (ActiveX DLL) installed. Tier 1 : ASP front End (IIS 5.0) Tire...
4
by: Rene' Nielsen | last post by:
Context: Running Windows 2003 Server on an intranet. A web is configured with an anonymous access account that is a domain account that has been granted the desired access to a file on another...
3
by: prodirect | last post by:
Hi all, I hope someone can help me. I've recently created a database and wanted to put it up on an ftp sight so that multiple people could access the same tables at the same time from different...
1
by: Z0gS | last post by:
I got this problem for the web application I try to access files on a remote server. string dirs = Directory.GetDirectories(@"E:\vehicles") E drive is a map to a network drive. I get the...
0
by: Joergen Bech | last post by:
Fairly new to ASP.NET 1.1. Getting the error below when running application on a web server outside of my control, but only the first time I run it: 1. After a long period of inactivity (or...
7
by: David Laub | last post by:
I've also posted this issue to a Sun/java formum, but since it appears to be an integration issue, this may be the better place to posr: I have written a dot net/c# Web Services doesn't fully...
8
by: Ben Fidge | last post by:
Hi I have a small WinForms app that needs to copy files from a shared drive on a network. If I connect to the mapped drive using Explorer, a password dialog pops-up and I have to provide...
4
by: accyboy1981 | last post by:
Hi, I'm looking to create a simple application that will copy files from a folder on one PC on the network to another PC on the network but I am having a bit of difficulty doing this. The...
4
by: Noy B | last post by:
Hi, I have developed a small application that is using a MSAccess DB. the problem is that it was developed on a machine where the application and the DB are both located. now it needs to be...
1
by: Usenet User | last post by:
From a .NET 1.1 app: need to access a file share on a remote server by its UNC path, i.e., \\server\folder\subfolder\, using specific username and password. The problem is that the credentials...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.