|
If I understand correctly, you are using the serial port.
In this case you should, simply use the SerialPort .Net resource
SkyWalker
|
|
|
|
|
If you were to need PInvoke for this, then I guess it would be
AutoOpenComPort(ref IntPtr Port, string ComAdr)
assuming ComAdr is an input argument, not returning anything to the caller.
If SerialPort is available (NET >=2.0) and can do what you need, just use it.
Luc Pattyn
|
|
|
|
|
Hi,
Please help me.
I need to write a get method that will return a my numbers as an array of long using C#.
Please help me. I am new to C#.
|
|
|
|
|
public long[] ReturnArrayOfLong(long urNumber)
{
long[] arrLong = new long[100];
arrLong[0] = urNumber;
return arrLong;
}
Jayant D. Kulkarni
Brainbench Certified Software Engineer in C#, ASP.NET, .NET Framework and ADO.NET
|
|
|
|
|
Hi All!
I am creating an Outlook add-in using C# and VSTO 2005. My problem is, whenever I read a mail item that is accompanied by a digital certificate and is encrypted (padlock icon on the left side of the email), I encounter this message:
"Unable to cast COM object of type ‘System.__ComObject’ to interface type ‘Microsoft.Office.Interop.Outlook.MailItem’. This operation failed because the QueryInterface call on the COM component for the interface with IID ‘{00063034-0000-0000-C000-000000000046}’ failed due to the following error: No such interface supported (Exception HRESULT: 0x80004002 (E_NOINTERFACE))."
The digital certificate came from Verisign, Inc.
How can I eliminate this and still read my email?
Thanks sooooooooo much for the help.
ayee
|
|
|
|
|
Probably, your item is not a MailItem (perhaps a ReportItem or whatever).
The Inbox can also hold other types of items. Use TypeOf to check the type of the item before you access any item specific properties or methods.
SkyWalker
|
|
|
|
|
Thanks for the answer.
I've tried all possible item types (like you said it could be a ReportItem etc.) but I still can't read the Inbox item. My progarm works fine if the Inbox Item is not encrypted (digitally signed only). Does the encryption have something to do with it? It's really driving me nuts...
Thanks again.
ayee
|
|
|
|
|
The encrypted mail items are not of MailItem type (or others related), therefore you cannot cast to it. Try to declare your variable as System.Object .
SkyWalker
|
|
|
|
|
I tried doing this but I can't seem to get to read the contents of the item (maybe I was doing it the wrong way). I also tried to follow the link about Collaboration Data Objects and Outlook Redemption and it just made me more confused. Apologies for my ignorance because this is the first time that I encountered them. Bottom line is, do i have to do it in the Outlook VBA environment? Or is there any other way (using C#)?
Thanks for being patient with me...
ayee
|
|
|
|
|
it should be ...
we just cannot pinpoint at the problem
SkyWalker
|
|
|
|
|
Maybe you find this[^] of some interest.
SkyWalker
|
|
|
|
|
I want to know how can i write a code to use (ping) from win 2000 to win200 or another operating system .
in c# or any scripting language .
Thanks for yr attention
my mail: syitonet@yahoo.com
|
|
|
|
|
i dont know about asp.net 1.0/1.1
but u can do this in... asp.net 2.0
under
System.Net.NetworkInformation.Ping
|
|
|
|
|
If you have NET 2.0 use the Ping class,
otherwise you will need a rather long piece of code (if so, let me know, I developed
a ping method for NET 1.x)
Luc Pattyn
|
|
|
|
|
hi,
In my solution contains five projects.
In one project i have progress bar.I want to increase progress bar value from other project.
help me out ,it's arrgent
Thanks
|
|
|
|
|
Hello,
There are a lot of ways to do that (actually it's a very often asked question).
You will olso find articles here on CP about that.
But I think fastest solution is using a static method for example.
public static void IncreaseProgressBar()
{
mystaticinstanceofmyform.myprogressbar.Value = ...;
}
All the best,
Martin
|
|
|
|
|
Thanks
But where i have to call this method.
one project is main from there i m calling other project class method.
the project in presentation layer.
another project in bussiness layer.
if u give information in detail some example or site address.
thanks.
|
|
|
|
|
I have a Windows Form application with a simple GUI that contains a progress bar. Pushing the button 'Start' on my form invokes some other project[ in same solution] classes that carry out a lot of calculations and database access. I want to show the user the progress of the program. The program is actually a loop of database migration that are handled.
My solution contains more the one project.
we have different layer.
Presentation layer.
bussines layer.
My question is: How do I make the progress bar update itself from other layer, when we dont have reference in bussines layer?
Thanks in advance for your help
|
|
|
|
|
I installed Multi SQL(sql 2000 and sql 2005) at home.
I want to get everyone of sql instance's name.
ex:in sql server manager,has a ServerName list
ServerName list:
vs\sql2k
vs\sql05
VS\SQLEXPRESS
"vs" is my computer's name.
I want to get ServerName list.
Thanks for anybody who give me help.
|
|
|
|
|
Please help me anybody!Thanks.
|
|
|
|
|
|
Thanks.
otherwise, I ain't intentional for it that post multiple messages for the same question.
|
|
|
|
|
You waited a whole 36 minutes between initial posting and repeat plea for help. If you need help that fast then I suggest you phone Microsoft support. for a fee they will answer any question on their products.
If you don't want to pay then you are at the whim of people who are giving up their time to help because they like to help, not because they are paid to help.
|
|
|
|
|
oh,sorry. I ain't intentional.
thanks remind.
|
|
|
|
|
Hi,
I have a problem with a datagrid.
I want to add an extra row to it, this works fine by building tablecells and add them to the grid for each entry in the grid.
The extra rows can be edited by the user, but I don't know how I can bind this extra rows to my datagrid, so the changes of the user are recognized by the webform.
can you please help me with my Problem, or is it impossible to add extra rows, that can be edited by a user?
thank you for your help
Peggy
|
|
|
|