|
|
What is the Top code in Dot. NET?
Hai this is Prabahar, working as a Software Engineer, in .NET Plateform for more than 3 years.
|
|
|
|
|
That's not a real question. Do you mean the best code, the best language, what ? I can't imagine a way to interpret it that gives it a cut and dried answer.
If someone asked me that in an interview, I'd say 'the code I'm going to write for you when you hire me'.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
|
First of all, is it possible usign .NET remoting feature inside a .NET
applet loaded into a tag object inside an HTML page ?
<object id="myID" height="150" width="300"
classid="http:applet.dll#test.applet">
If not please can anyone explain why ?
I think yes and so I'd written a small example immediately I've met a
problem.
I'm using .NET Framework v. 1.1.4322 and it's the only version
installed both client side and server side.
My test applet is correctly loaded into IE client but when I try to setting programmatically the remoting I aways obtain a SecurityException even if the assembly is strong name signed and client side fully trusted.
The exception is the following: <br />
System.Security.SecurityException: Request for the permission of type System.Security.Permissions.SecurityPermission, mscorlib, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 failed. <br />
at System.Security.CodeAccessSecurityEngine.CheckTokenBasedSetHelper(Boolean ignoreGrants, TokenBasedSet grants, TokenBasedSet denied, TokenBasedSet demands) <br />
at System.Security.CodeAccessSecurityEngine.CheckSetHelper(PermissionSet grants, PermissionSet denied, PermissionSet demands) <br />
at System.Runtime.Remoting.Channels.ChannelServices.RegisterChannel(IChannel chnl) at test.applet.Check()
Could anyone help me please ?
Best regards
|
|
|
|
|
1.I create a strong typed dataset.
2.I bound the table from the strong Typed dataset to a DataGridView.
3.User Click on a row and press "Select" button. I can just cast the selected row with code below:
<br />
this.returnedRow =<br />
(TypedDS.MasterGroupSearchRow)this.dgvMasterContract.CurrentRow.DataBoundItem; <br />
4.At this moment the
this.dgvMasterContract.CurrentRow.DataBoundItem is (TypedDS.MasterGroupSearchRow)
But if After Click on the column header .. problem come out ...
this.dgvMasterContract.CurrentRow.DataBoundItem will become System.Data.DataRow.
So code below will fail ..
<br />
this.returnedRow =<br />
(TypedDS.MasterGroupSearchRow)this.dgvMasterContract.CurrentRow.DataBoundItem; <br />
Is there anyway to solve this problem ? or is there anyway to preserve it original typed row ?
|
|
|
|
|
Check the type before you process the OnClick event?
Is this a web grid view or a winform gridview?
|
|
|
|
|
Hello!
Ive got a solution with about 10 projects. I recently changed assembly version in all projects from [assembly: AssemblyVersion("1.1.0.0")] to [assembly: AssemblyVersion("1.1.0.1")].
When I now rebuild the solution and run the program I get this: System.IO.FileLoadException: The located assembly's manifest definition with name 'X' does not match the assembly reference.
File name: "X"
What did I miss?
/Regards
|
|
|
|
|
When you set your references between projects, did you set the reference to another projects .DLL file, or to the project itself?
If you set it on the .DLL file, this can cause the problem your having.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hello Dave
I set in on the project itself.
/Regards
|
|
|
|
|
OK. If that's the case, then you have the older project .DLL's copied into the .EXE's Debug and Release folders, or somewhere else on the PATH. Search the drive for the names of the .DLL's and see if you have stray copies running around.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I have a similar problem.. but changing the reference to project reference didn't resove the problem...
In visual I clearly see reference to a project with version 1.1.x.1
But when I check with the .net configuration utility the assembly dependecy points to version 1.1.x.2
And If I check with lutz .net Reflector I see the reference to version 1.1.x.1
But when I test my app it is clear that the dependecys in .net config utility is right because it gives an error tha it can't find 1.1.x.2
This seems so strange.....
Please help !
thank you
|
|
|
|
|
Same answer. Search the drive and find all the copies of the .DLL's involved. Wipe them all out. If you have them registered in the GAC, unregister them first. Once you have them cleaned up, rebuild the entire project. Make sure of your project dependency order first, the rebuild the entire project.
You can find out more about how the runtime locates and loads assemblies here[^].
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Thank you for this usefull information, But I'm still confused why you get different references on the same dll with reflector and .net configuration utility ...
|
|
|
|
|
I don't know. I haven't seen that behavior and I can't duplicate it myself.
I keep my Assembly Versions completely manual. That means that there are no * in the version assembly version numbers. I also don't copy my .DLL's around and I don't set references to them unless they are libraries that I use in multiple projects and I've installed them in the GAC. Otherwise I set references to the .DLL's Project, not the .DLL itself. This keep versioning nice and neat and avoids problems with "whatever version cannot be found" errors.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I wants to capture video from digital camera by using c# form.........PLZ Help me
khalid mahmood
|
|
|
|
|
Search for DShowNET on CP.
As of how to accomplish that have you ever tried Google?
Failing that try .
|
|
|
|
|
hi there
i have a form with many controls. when i will make final version my apllication will run slow because of that manny controls???
all my controls are from standard like labels, combo, textbox's ,datagrid..etc
if the answer is yes, what to do to avoid slow motion in use of my software?
|
|
|
|
|
Standard controls are going to be fine. Really, it depends, if you have a speed issue, then you need to look at what could be causing it, but with the speed of PCs nowadays, it's not likely you need to worriy
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
How do i de install .NET framework 1.1 and re install it. i have .NET framework 2.0 on the same machine and its a windows 2003 server.
How do i do it
|
|
|
|
|
I suspect some thing is messed up with the .NET 1.1 and so i want to reinstall that
The reason i came to that conclusion is that a .NET application i wrote previously which was working previously well is now generating an error
"Application has generated an exception that could not be handled process id = .... Thread id = .... "
The same application works perfectly on my computer and i know that it worked perfectly two days before too on one of our customer computer and some thing was done on that server afterwards.
Well i want to know if there is an easy way to remove it and reinstall it its on windows 2003 server. It does not show up in Add Remove Programs. When i just run dotnetfx.exe(redistributable package) it says its already there.
|
|
|
|
|
|
Seems more likely to me that the PC it's crashing on is showing you a problem in your code that depends on user settings or something like that.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Is there anyway of reducing the runtime of the .Net projects that I have done. Currently its taking too muh time.
|
|
|
|
|
That's a really vague question. What do you mean by "reducing the runtime", "taking too much time"?? Too much time for what?
The biggest problem with performance is writing inefficient code...
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|