|
I've just been working on a custom multiple select tree control (the ones here at TCP did not satisfy the requirements) and I'm running into a problem. I maintain a hash table of selected nodes and everything is hunky-dory until I start deleting nodes from the underlying TreeView "Nodes" TreeNodeCollection. A client could knock a selected node (node in the selection table) out of that collection and I'd have no way to tell my class to remove the node from the selection table.
Is there some event to listen in on for this? I could write some methods in my custom TreeView class like 'remove node' or something, and make a big note in the comments that future clients need to use that... but that's not good enough for me.
Any suggestions??
|
|
|
|
|
hi!
i want to send a POST HTTP Request to a Web Server!
Here i got some information:
http://msdn2.microsoft.com/library/debx8sh9(en-us,vs.80).aspx[^]
my problem is: how can i send such a POST Request, with the JSESSIONID from the GET Response before and the POST Data!?
<br />
POST /webkeeper/Controller HTTP/1.1<br />
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, application/x-gsarcade-launch, *
-> the username and password i dont want to show here, thats the reason for the letters: *****
the JSESSIONID i got from a GET HTTP Response:
<br />
HttpWebRequest request1 = (HttpWebRequest)WebRequest.Create("https://www.myzone.at/webkeeper/Controller");<br />
request1.CookieContainer = new CookieContainer();<br />
<br />
HttpWebResponse response1 = (HttpWebResponse) request1.GetResponse();<br />
response1.Cookies = request1.CookieContainer.GetCookies(request1.RequestUri);<br />
<br />
Console.WriteLine ("HTTP/" + response1.ProtocolVersion + " " + response1.StatusDescription);<br />
Console.WriteLine (response1.Headers.ToString());<br />
<br />
String sessionid = "Set-Cookie: ";<br />
sessionid += response1.Cookies[0].ToString();<br />
cu+thx
|
|
|
|
|
You have a complete example on the page you linked to. What is missing?
---
b { font-weight: normal; }
|
|
|
|
|
i, now it works
but...when i want to use managed c++ then i need a c++ compiler oder a c# compiler? can i compile it with dev-cpp and g++?
cu
|
|
|
|
|
Can someone tell me how a cell within a datagrid can be created or modified to span more then one column, like HTML's 'colSpan' ("Column Span")?
Here's what I'm trying to do:
Column Header 1 | Column Header 2
---------------------------------
Data 1 goes here | Data 2 goes here
---------------------------------
Data 3 goes in this wide cell
---------------------------------
Thanx.
|
|
|
|
|
|
I have a small quiz-like thing, with 30 Q's but you only do 10 each time you take the quiz.
So to get random Q's im using Random() and switch().
But you dont want the same Q twice, so i could create a value for every question that changes when the Q is asked, but thats a bit of a pain.
Is there any easyer way to check whether a Q has been asked?
|
|
|
|
|
You could do random shuffle with questions, and then use them seqentionaly. This way, you'll get random order and won't ask same question twice.
David
|
|
|
|
|
btw you should write "easier"
David
|
|
|
|
|
I know
But im just too damn lazy to change it
|
|
|
|
|
|
Hi,
I just started looking at this new typed app.config in Visual Studio 2005 and I must admit I'm very confused. I Googled quite a bit to find more information but could not found anything usable. I have a few questions and I appreciate if some of you could take the time to answer them.
1. How do I encrypt connection strings in Windows Forms apps. I read that it can be done automatically for ASP.NET apps, but this feature seems to have been left out of WinForms. Am I right? Do I need to manually code this or there's an automated way?
2. It seems that the config file is stored in a path that ends with the version number of the application (ie: c:\......\v1.0.0.0). What happens if users upgrade to v1.0.0.1 for example? Will they lose all their settings? How can I prevent this from happening? Can I store my app.configs in a version independent path (user settings and application settings)?
3. How can I access my UI project's settings from class libraries (other assemblies)?
4. How is app.config deployed with ClickOnce?
5. Why is Visual Studio 2005 creating app.configs for all the projects of my solution? It doesn't make sense to me, it should only create one for the UI project. Maybe this is a beta bug?
Thanks a lot for your help and time!
Carl
|
|
|
|
|
I've created a non-rectangular windows application and have placed the Windows Media Player control on top of one portion of the form. I have set my transparent color to reflect the color around my non-rectangular background image. When I run my application and set the URL for the WMP control, I do not see the video. If I select the form, then the transparent color is visible. I'm not sure why the redraw doesn't work properly and only screws up if the URL is set for the WMP control. Does anyone have any ideas? Thanks.
|
|
|
|
|
I have a combo box that I want to put 35x35 pixel images into. How do I allow this to display images. If that works, do I still just do a combo box selected item to use that image somewhere?
|
|
|
|
|
|
Hello everybody!
OK, simple question here, how do I convert a TXT file that has a line ending of CR or LF to CRLF? I tried reading each line with StreamReader, replacing "\r" or "\n" with "\r\n", and writing the line with StreamWriter.Write(), but it doesn't work!
What else could I try? Thanks!
Darth_Sulfur (Sulfurik)
http://www.SulfurSoft.tk
ftp://tsfc.ath.cx
http://tsfc.ath.cx
hotline://tsfc.ath.cx
|
|
|
|
|
Does reading the whole string into memory (using ReadToEnd ) and replacing "\r" or "\n" with "\r\n" work?
Regards
Senthil
_____________________________
My Blog | My Articles | WinMacro
|
|
|
|
|
When you read a line, it does not return the CR, LF, or CRLF, so replacing them won't work. Instead, just read the line in and write it back out with StreamWriter.WriteLine().
|
|
|
|
|
strText = strText.Replace(Microsoft.VisualBasic.ControlChars.Cr, Microsoft.VisualBasic.ControlChars.CrLF)
"People who never make mistakes, never do anything."
My blog
http://toddsnotsoamazinglife.blogspot.com/
|
|
|
|
|
|
YES! ReadToEnd() worked! Thanks you all!
Darth_Sulfur (Sulfurik)
http://www.SulfurSoft.tk
ftp://tsfc.ath.cx
http://tsfc.ath.cx
hotline://tsfc.ath.cx
|
|
|
|
|
I need to generate Excel Reports using Pre-Created Excel Template.
Data is fetched from the databse. Does any one know any managed open source tool
to achieve this? All help is appreciated.
|
|
|
|
|
Hi there!
I made an application that needs to give the number of UDP packets that pass in port 1024.
The program is the following
while(received_data != 0)
{
received_data = exp.udpclient.ReceiveFrom(exp.udpbuffer, 0, exp.udpbuffer.Length, SocketFlags.None, ref exp.udpep);
count++;
}
This program work fine in Windows, but the problem is that using ethereal I found that windows don´t receive all the packets that the server send. In Linux, ethereal receives all the packets that the server send. But my program running in mono, don´t receive all the packets =/
Anyone can help me to find a solution for this?!
The problem of performance is in mono, or is ReceiveFrom from the socket?!!
Thank you.
I hope to hear you soon.
|
|
|
|
|
|
UDP is a connectionless protocol. There is no gaurantee that any client will receive all the packetssent by any particular sender...basically UDP is just send and pray...
Absolute faith corrupts as absolutely as absolute power
Eric Hoffer
The opposite of the religious fanatic is not the fanatical atheist but the gentle cynic who cares not whether there is a god or not.
Eric Hoffer
|
|
|
|