|
hi,
please if any one knows how to integrate .net framework with autocad or with 3d studio max using dll or something like that, post the reply as soon as possible.
thanks very much .
|
|
|
|
|
I had finished my project and I want give to my frien. How should I biuld my project, that it work at my friend computer (he don't have .Net framework)?
|
|
|
|
|
thesad wrote: he don't have .Net framework
Then he must install it.
|
|
|
|
|
then how create setup? I use visual studio c++ 2005 express edition.
|
|
|
|
|
Good Day to All,
I created a software for my school that allows the proffessor to instantly distribute a file or a folder to every student's terminals.
My problem is that when we tested it in our school, I get two exceptions. First is a Security Exception and a FILE IO Exception.
After much reading, I found out that there is a so-called "mscorcfg.msc" and by default, if the user is not an administrator, he won't have enough permision.
So what I did was, I configured my computer at home for a "USER" to have "FullTrust". Indicated on the mscorcfg.msc is the config file is located at "C:\Documents and Settings\<username>\Application Data\Microsoft\CLR****\V2.0****\security.config"
So My question is, Will it work if I copy the security.config from my house then manually copying it to my proffessor's terminal to get rid of the exceptions?
Thank you in advance.
|
|
|
|
|
That would unwise.
The computer your professor uses will be inside a the college or university network which has its own set of security settings. Copying settings from your home to your university will most likely have an adverse reaction on other applications that are being run.
|
|
|
|
|
Hi All,
I definition of .NET FRAMEWORK - all class object ( except int, char and ext. ) are sending to function as reference.
So in witch case i need to use ref/out in declaration of function ?
Thanks for any help.
|
|
|
|
|
Hi,
without out/ref function arguments are passed:
- by value (=the value of the thing is put on stack) for value types such as int and struct
- by reference (=the address of the object is put on stack) for reference types such as Form
with ref added, an additional indirection is used, which means when the function argument
was some variable, rather than passing the variable (as stated above) a pointer to it gets
passed, allowing the callee to modify that variable.
This allows for a method to have multiple outputs: one return value and any number of "ref"
arguments.
So you could create a method
void getThreeCoordinates(ref int x, ref int y, ref int z) {x=1; y=2; z=3;}
When called as:
int a=2, b=3, c=4;
getThreeCoordinates(ref a, ref b, ref c);
all three local variables would be changed.
A ref argument needs to have a value before it can be passed with ref; an out argument does not.
(So the example would not need initial values if out had been used).
All of this can be found in any reference manual on C# of course.
|
|
|
|
|
All this i already know.
But if (for simple example) in my program i passing only class object that are passing as reference types - then when do i need to use the ref/out ?
From what i see - in this case - if i will not use the ref/out i will have same result any way.
What i missing here ?
|
|
|
|
|
Hi,
you dont HAVE to use ref/out, but sometimes you can make good use of it.
BTW the ref/out is part of the argument list's signature used in matching method
calls and methods.
To illustrate its effect:
ArrayList list1=new ArrayList();
ArrayList list2=list1;
list1.Add("a");
list1.Add("b");
show(list1, list2);
do1(list2);
show(list1, list2);
do2(ref list2);
show(list1, list2);
...
public void do1(ArrayList list) {list.Add("c"); list=new ArrayList(); list.Add("d");}
public void do2(ref ArrayList list) {list.Add("e"); list=new ArrayList(); list.Add("f");}
with appropriate show() method will output
(a,b) (a,b)
(a,b,c) (a,b,c)
(a,b,c,e) (f)
because do2 changes the variable list2, whereas do1 does not.
|
|
|
|
|
Has anyone experienced this, or a workaround?
I am using a WebBrowser control to display an xml file from the file system. The size of the xml file is 190k. Everything is fine except when I close the control (say using a tabbed interface). When closing/removing the browser control, the application experiences a large delay (~7 secs on my machine). Internet Explorer (7) does not show this behavior; it loads up the file at the same speed (as me) and closes immediately with no delay.
Any insight would be appreciated. Here is the code I refined down to illustrate the problem.
private void Form1_Load(object sender, EventArgs e)<br />
{<br />
<br />
TabPage page = this.tabControl1.TabPages[0];<br />
WebBrowser wb = (WebBrowser)page.Controls[0];<br />
wb.Navigate(@"D:\temp\large.xml");<br />
}<br />
<br />
private void button1_Click(object sender, EventArgs e)<br />
{<br />
this.tabControl1.TabPages.Remove(this.tabControl1.SelectedTab);<br />
}<br />
Michael
Developer, Author, Chef
|
|
|
|
|
Well, it seems whenever i ask a question I figure out a workaround. In this case, I am still not 100% sure why this works. And yes, the DoEvents() is necessary for this the page to close quickly (due to asnync loading I guess).
private void button1_Click(object sender, EventArgs e)<br />
{<br />
<br />
WebBrowser wb = (WebBrowser)this.tabControl1.SelectedTab.Controls[0];<br />
wb.Navigate("");<br />
Application.DoEvents();<br />
this.tabControl1.TabPages.Remove(this.tabControl1.SelectedTab);<br />
}<br />
Michael
Developer, Author, Chef
|
|
|
|
|
Hi !
I need to implement udp protocol in C#/VB.net Win Forms that send some request to the broadcast address from specific port and then change to be client and receive multiple answers from the broadcast on the same specific port.
My questions are:
1.Is the first connection should use blocking (synchronous) functions ?
2.Should I close this first socket,and then open another one on the same port in order to get the broadcast answers ?
3.In which way should I get the broadcast answers:a.using asynchronous function and events like BeginSend/EndSend etc or b.using threads ?
4.How do I get multiple answers on the same port in this case ?
I will be glad to get answers/code snippets.
Tnx
AliJ
|
|
|
|
|
Hi,
There are two properties on MailMessage object in .Net 2.0:
MailMessage.From
MailMessage.Sender
Can anyone tell me the difference between the two? Thanks!
Sindy
|
|
|
|
|
Taken from the Internet Message Format RFC (RFC 2822)[^], section 3.6.2. Originator fields.
The "From:" field specifies the author(s) of the message, that is, the mailbox(es) of the person(s) or system(s) responsible for the writing of the message.
The "Sender:" field specifies the mailbox of the agent responsible for the actual transmission of the message. For example, if a secretary were to send a message for another person, the mailbox of the secretary would appear in the "Sender:" field and the mailbox of the actual author would appear in the "From:" field.
If the originator of the message can be indicated by a single mailbox and the author and transmitter are identical, the "Sender:" field SHOULD NOT be used. Otherwise, both fields SHOULD appear.
In all cases, the "From:" field SHOULD NOT contain any mailbox that does not belong to the author(s) of the message.
-----------------------------
In just two days, tomorrow will be yesterday.
|
|
|
|
|
This is not as easy a question to answer as you might think. Identical IL code produced from the different compilers will run in exactly the same way, so there is no performance hit. However, you don't have to produce IL code out of VC++.NET. With this, you can produce native code which, if properly implemented and optimized, should run faster than the IL equivalent.
Similarly, you have to question whether the different compilers will actually produce identical IL code. In most cases this is true, but there is the possibility that one compiler will produce slightly different code because of the priorities and design decisions of the appropriate compiler team.
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Don't you just hate when, you go through all the trouble of posting an nice answer like this, the OP goes back and rudely deletes their question??
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Dave Kreskowiak wrote: Don't you just hate when, you go through all the trouble of posting an nice answer like this, the OP goes back and rudely deletes their question??
I do indeed. That's why I'm going to leave my post, so yours won't be left hanging around.
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
I'm glad you did. It helped explain why my answer to this post[^] was intermixed with your posts.
It does tend to make things a little confusing.
-----------------------------
In just two days, tomorrow will be yesterday.
|
|
|
|
|
Hello,
I have a class, let's say, Document and a class which inherits from Document: DocumentLinked
DocumentLinked adds an extra property, linkedId
Now I'm searching through a list of documents, and I want to select some of them, and create DocumentLinked-objects out of them. But conversion fails.
I tried Ctype overloading, which, according to the compiler, I cannot do because I would convert from a base-class.
I quite bummed here.
Some code:
Public Class DocumentLinked
Inherits Document
Private _linkedId As Integer
Public Property LinkedId() As Integer
Get
Return _linkedId
End Get
Set(ByVal value As Integer)
_linkedId = value
End Set
End Property
End Class
'...
' selectedDocument is instance of Document
' linkedDocument is List( Of DocumentLinked)
doc.LinkedDocuments.Add(CType(selectedDocument, DocumentLinked))
|
|
|
|
|
bertburtbort wrote: Now I'm searching through a list of documents, and I want to select some of them, and create DocumentLinked-objects out of them. But conversion fails.
The objects are Document s, they are not DocumentLinked objects. You cannot convert cast a reference from a Document to a DocumentLinked unless the actual object being referenced is already a DocumentLinked object already.
If you want to convert the document then you are going to have to create a new object of the correct type and copy the relevant stuff in.
-- modified at 5:51 Thursday 22nd February, 2007
|
|
|
|
|
So there is no way to convert downward in the inheritance-chain?
Now I think of it, it makes sence
|
|
|
|
|
bertburtbort wrote: So there is no way to convert downward in the inheritance-chain?
That depends on what you think is down. To me down means towards object because that's at the base of everything.
Also, be careful with terms like convert and cast. You cannot cast to a derived class unless the object is at least as derived as the class you are casting to. You can convert to anything if you write the code for it.
|
|
|
|
|
I have to use reporting tool which is available in 2.0 in my application which is in dot net 1.1, if i will use this 2.0 reporting tool then will it have any kind of impact on the application or anything, please reply soon.
|
|
|
|
|
If the reporting tool is to be used as part of your .NET 1.1 project (i.e. added via a reference), you are in for a nasty surprise. You can't link .NET 2 into .NET 1.1.
If it's a separate application, then there isn't a problem running the two runtimes.
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|