|
Yoyosch wrote: U dont understand. I wrote clearly that I`m looking for such module. I don`t intend to write myself.
You don't understand. It is "wrote clearly" in the forum guidelines that no one will write code for you. You will be hard-pressed to find what you are looking for. I am almost 100% confident that you will have an even harder time finding what you are looking for, free of charge. Learn to use google, you are going to need it to do the research. Good luck
I'm going to become rich when I create a device that allows me to punch people in the face over the internet.
"If an Indian asked a programming question in the forest, would it still be urgent?" - John Simmons / outlaw programmer
|
|
|
|
|
Hi all
I have an inherited control from standard textbox control. In this textbox control i set some default property value to new one.
<br />
this.BackColor = System.Drawing.Color.Red;<br />
<br />
In this case when user place my derived control to a form designer generate in InitializeComponent() this rows
<br />
<br />
((System.ComponentModel.ISupportInitialize)(this.derivedTextBox)).BeginInit();<br />
....<br />
this.derivedTextBox.BackColor = System.Drawing.Color.Red;<br />
<br />
<br />
As a result when form are created DerivedTextBox.BackColor property invoked 2 times. First -
when control created and Second - in the InitializeComponent() method of form where placed.
I know that in this example it dosn't matter but actually i have other base control (not text box), what can add to oneself buttons [for examp: this.Buttons.Add("MyNewButton") - base control by default not have this button, but in derived it shoul be], and since what every time when i want to add button to this control one add two times)
And now i have question, is exists an event what invoked only when control added to a form???
Or where in code i should write initialization control code so as this code will only generated in InitializeComponent() method of form and not to bee invoked when control are created????
THANK.
|
|
|
|
|
if you have a constructor in your derived class then inherit the base class constructor, like:
MyTextBox(): base()
{
}
i think you should use ControlAdded Event
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
How to store files(.doc files,.zip files) in a database and how to retrieve them
|
|
|
|
|
Are you using Oracle or SQLServer database? The concepts are the same for both, but the terminology is a little different.
If you are talking about Microsoft SQL Server then you will be looking at storing and retrieving a BLOB (Binary Large Objects). If you look up Microsoft SQL Server and BLOB you should be able to find all the resources you need to get started.
Try this to start with:
http://support.microsoft.com/kb/309158[^]
Hope this helps
Aaron
_____________________________________________________________________
Our developers never release
code. Rather, it tends to escape, pillaging the countryside all around.
The Enlightenment Project (paraphrased comment)
Visit Me at GISDevCafe
|
|
|
|
|
very thanks for reply me
|
|
|
|
|
IO.Directory.GetFiles("C:\\Windows"); will get me all the files in the windows directory, but is there a way to get all the absolute path names to these files that IO.Directory.GetFiles(path) finds??
|
|
|
|
|
Have a look at the Path Class[^] It has several functions which can help you.
|
|
|
|
|
hi friends.
I have converted a doc or image file to byte code by this code.
-------------------
FileStream fs = new FileStream(filePath, FileMode.Open, FileAccess.Read);
int length = (int)fs.Length;
byte[] content = new byte[length];
fs.Read(content, 0, length);
--------------------
Now i want to convert this "content" i.e array of byte to actual file.
at the time of conversion in which object should i store the output (because i don't know the type of file i had converted to byte code).
How to do this.
(basically i m sending a file(image,doc,txt etc) from one machine to another remotely).
Hope you understand what i want to do here.
Thanks lot.
|
|
|
|
|
Just use Write method instead of Read and pass the byte array you have to it.
FileStream fs = new FileStream(filePath, FileMode.Open, FileAccess.Write);
int length = content.Length;;
fs.Write(content, 0, length);
|
|
|
|
|
and how to convert it back into a file??
|
|
|
|
|
It will be a file. Just don't forget to close the stream when you've done writing to it. Also, you might want to create the file first if it doesn't exists
|
|
|
|
|
I think your question related to knowing what type of file to save the byte stream as on your target machine? mr. Dalakishvili has told you how to save ti to your target path, all you need do is keep the same extension and it should work fine.
|
|
|
|
|
-------------------
FileStream fs = new FileStream(filePath, FileMode.Open, FileAccess.Read);
int length = (int)fs.Length;
byte[] content = new byte[length];
fs.Read(content, 0, length);
--------------------
ah, a long way to convert a file into byte[],
try
byte[] mybytes = File.ReadAllBytes(filePath);
to write byte(back to file)
File.WriteAllBytes(filePath, mybytes);
hope this will help
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y<p?jxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hi
Can someone please help me... It's seem like there is not a single way to get the column size from a dataset, table, datarow from SQL/Oracle in .Net using C# or VB
Thanks in advance
|
|
|
|
|
|
how to create folder in run time.
hai when i register my details create a folder in my name using .net with c#.if u know the code replay me.
modified on Wednesday, February 27, 2008 6:17 AM
|
|
|
|
|
|
thank u for your replay.
but i need .net with c# coding.
|
|
|
|
|
sugunavathysubramanian wrote: thank u for your replay.
but i need .net with c# coding.
And he gave you a link to the information that will aid you in writing the code. Part of being a developer is being able to research topics, understand it, then use what you learned to write the code you require. People here don't do your work, they help with specific problems. Tty to write the code yourself, and if you have a specific question, reply on THIS THREAD.
I'm going to become rich when I create a device that allows me to punch people in the face over the internet.
"If an Indian asked a programming question in the forest, would it still be urgent?" - John Simmons / outlaw programmer
|
|
|
|
|
|
Hi All,
I am handling keypress event for a RichTextBix control on my windows form. But, when i press a key on it, why its entering two times into keypress event code instead of once.??
I have added event handler only once on my form.
could anyone please suggest me how can I overcome this problem?
Thanks,
Durga.
Strength is life, Weakness is death.
--- Swami vivekananda
|
|
|
|
|
The delegate that handles the event raised has the invocation list of the methods to be called. It could be a reason that the code where the event is registered is called twice in the code execution, so check that out; the statement '+=' should be called only once when the form is loaded and the controls are created and added to it.
Muhammad Talha
|
|
|
|
|
Hi,
thanks for the reply. I'm sorry that it was my problem i added the event handler twice inadvertently.
Strength is life, Weakness is death.
--- Swami vivekananda
|
|
|
|
|
I am doing some asynchronous operation(Webclient.DownloadFileAsync() ) which is working on a separate thread. This will raise some events when the download process finished. Is it possible to stop the current thread until these events are fired ? Inside the event handler, I need to resume the thread. Any idea's ?
|
|
|
|