|
My best bet is about the use of design patterns in WinForm.
Best,
Jun
|
|
|
|
|
Hi guys! Help please I am a newbie in C#, I have been working on an application and was working fine on MS Visual C# .Net and then yesterday I downloaded and started converted the application to MS Visual C# 2005. Now on one of the forms I am getting an error when I try to open the form. i.e. form.showDialog(); the error says Invalid OperationException was unhandled and that DragDrop registration did not succeed. Please help! what does this error mean?
sasa
|
|
|
|
|
|
Hi Mike,
I don't have configuration properties under my project properties. I am using MS Visual C# 2005 express edition. Are you going Project-->project properties--->Configuration properties? I went this way and when I go from Project--> project properties, there is no configuration properties or anything about STA threading, please advice?
sasa
|
|
|
|
|
|
Well Dears!
I need some help to convert my Existing C# 2.0 (Database SQL EXPRESS) Application from English to Multilingual(Preferably THAI). I have got all labels and Strings Translation. And now ready to start working but unable to start as i am confused where to start.
And wht about the database that i have already designed and developed written all procedures and functions etc. Would i need to modify my DB END too(table fields,procedures, functions etc).
And i need some easy way to do it that is helpful in future also as i m supposed to convert it to some other language in the future.
Any articles and suggestion would be highly appreciated
THNX IN ADVANCE.
|
|
|
|
|
Hi
Resource based application is one of the best solution for Multilingual Applications. Don’t bother about back-end, just convert the field types Char to Nchar and Varchar to Nvarchar, then it supports any type of languages.
Chandru
|
|
|
|
|
There are several examples of how to create an IE toolbar in C# on CP. All are based on this article posted http://www.codeproject.com/csharp/dotnetbandobjects.asp[^]
The one issue that I am having is that my toolbars refuse to move to a new row. I can move my tool bar to any band (row) but if I keep moving it down, to below the lowest band, it will not add a new one. All other toolbars can be moved to a new row/band. Just not mine.
Well actually, if I look very carefully, it does. Its very very very narrow. I have tried nearly every trick, but I just cannot get this to work.
Any ideas?
|
|
|
|
|
Fixed it. The sample code had a bug in it. in GetBandInfo ptMinSize.Y was being set to -1. So if another toolbar had not created any height for the band, your toolbar would get squished.
|
|
|
|
|
Hello,
I am drawing a table in the OnPaint method of a windows form. I would like to add Rectangles to the page that will fire an onclick event when I click on them. Does anybody know how to accomplish this? As far as I can see, the rectangle object doesn't have that kind of functionality built in... I originally just tried using buttons, but since I need quite a few of them, it is taking too long to draw them.
Thanks for your help!
RC
|
|
|
|
|
VS 2005 has a new control called "TableLayoutPanel". You may want to try this before writing your own rectangles. The panel certainly supports click events. Check this CP article[^].
Best,
Jun
|
|
|
|
|
It seems a mdi child window maximum size is 1036*768 ...
is this true or what am I doing wrong ?
modified 30-Nov-21 21:01pm.
|
|
|
|
|
Hi all,
Right now, I'm struggling with finding a solid way to determine what sort of string the user has input. The strings I want to support are URLs, paths to files, or network paths. I've tried playing with the UriBuilder class and just building my own string "URI" (properly formatted so the URI class doesn't throw an exception).
Does anyone have any ideas? Pointers on where to look? I know that URIs can do most of this, but it doesn't seem to like network paths and is pretty prone to exceptions.
Thanks in advance!
-llamaindustries
-- modified at 18:43 Friday 23rd June, 2006
|
|
|
|
|
Hi
Does anyone know how to convert a byte array to a bitmap image in c#???
any bit of onformation would be usefull.
thnx in advance
Jailan
|
|
|
|
|
Jailan wrote: convert a byte array to a bitmap image in c#
Save it to a file name ended with ".bmp"
Best,
Jun
|
|
|
|
|
What does the byte array contain?
a) The full bitmap with headers and pixel data: Write in into a MemoryStream and create an Image with Image.FromStream().
b) Only the pixel data: Copy the array into unmanaged memory, create new Bitmap with the expected width, height and PixelFormat , lock all bits and set Scan0 to the first element of the unmanaged array. Go on, just copy the code from this FAQ^.
_____________________________________________________________________________
I don't expect too much, all I want is your vote for Halbsichtigkeit.
|
|
|
|
|
Hello. For a project i am currently working on, i need to be able to send data, images specificly, between computers using sockets. Unfortunately, i have had some diffuculty making tcp transfer the data. I've been trying to use NetworkStream.read() and NetworkStream.write(), but for some reason the image always gets messed up in transfer. I tried sending the data in 32 byte bursts, but the image still arrives with serious errors in it. What is the fastest and most reliable way to send byte arrays across computers, preferably with streams?
P.S.
a few lines of code would be extremely helpful
-- Steven Hunt
|
|
|
|
|
Search CP for "tcp" filtered by C# and you'll get tons of artciles.
Best,
Jun
|
|
|
|
|
Hello
I've already been sending images across LAN networks using sockets, but strangely I didn't face your problem!!
Your post raises some points:
1- Try checking your method of sending data. Do you send other data than images? Are there any problems in any of the other types?
2-Are you sure you are reading the bytes of the image corectly? Try after reading the data, and just before sending it using the NetworkStream, try to convert it back to Image, see if it works.
3- I have been converting my data from Bytes to strings using Encoding.Default.GetString() method before sending them across the NetworkStream, maybe you would like to try this
4- If you still having problems try to use the Socket.Send() and Socket.Reveive() methods instead?? perhaps??
I hope this was helpful.
|
|
|
|
|
CREATE PROCEDURE MasterProc
@className nchar , --Class Name to load.
@pList nchar
AS
EXTERNAL NAME MasterClassAssembly.MasterClass.CallClassSP
EXEC MasterProc 'PInfo','1'
CallClassSP is a method in MasterClass(regitered as SQL Server assembly) which dynamically loads a class based upon the parameter passed in the Stored Procedure.
When trying to run a CLR Stored Procedure, I am gettting the following error.
Msg 6522, Level 16, State 1, Procedure MasterProc, Line 0
A .NET Framework error occurred during execution of user defined routine or aggregate 'MasterProc':
System.Security.SecurityException: Stack walk modifier must be reverted before another modification of the same type can be performed.
System.Security.SecurityException:
at System.Security.CodeAccessSecurityEngine.Assert(CodeAccessPermission cap, StackCrawlMark& stackMark)
at System.Security.CodeAccessPermission.Assert()
at MasterClass.CallClassSP(String className, String sList)
Thanks for the help
Anurag Jain
|
|
|
|
|
I am using a DataGrid control (from SyncFusion) and want to allow users to
(1) copy cells from one part of the grid and paste it to another part of grid
(2) copy cells from an Excel and paste it on the grid
I am kinda new to gui development and have to maintain this code. I'll appreciate your help.
Thanks
Dinesh
|
|
|
|
|
I have made an application in C# that uses a lot of PInvokes to the Win32 that create shared memory using VirtualAllocEx and more. I have a pretty bad memory leak now. Surprise! I have no experience dealing with this problem. What is the best way to find memory leaks in NET? Or do i simply try random things and cross my fingers?
|
|
|
|
|
If you're using native calls to allocate memory, you need to use the same to deallocate it as well.
|
|
|
|
|
Hallo,
I saw that ddraw was removed in dx9, so we must use d3d to create 2d-games/graph.
Ok, I read about textures and sprite.draw2d etc.
The problem is:
I use, for test, mspaint to draw the sprite (bitmap 256 colors) with white as a background color.
I didn't understand how telle to d3d to remove the background and draw only the sprite, say a red man on white background: how can I draw only the man without the white background??? Using alpha color for black: Color.FromArgb(0xff,Color.White).ToArgb(); d3d draw the white color as a black opaque and no trnasparent, so the sprite background cover the scene-color.
In simpler words when I draw the sprite in a device cleared with color blue the result is: the device totally blue and in the middle a black rectangle with the red man inside.
Hope I explained right
Thank you
CometKeeper... A Dreams Guardian... (Italy)
|
|
|
|
|
is there any way to send a file from one program to another program each running on different PCs of lan.........i have done it using sockets but its a byte reading procedure....and i have to write it to a file ....i want to send file which the other program should reccieve as a whole in some file object
jadoo
|
|
|
|