Click here to Skip to main content
15,916,835 members
Home / Discussions / C#
   

C#

 
GeneralRe: updating error using oledbcommandbuilder Pin
ginji2015-Jun-08 17:30
ginji2015-Jun-08 17:30 
Questionout variable assignment Pin
George_George15-Jun-08 15:13
George_George15-Jun-08 15:13 
AnswerRe: out variable assignment Pin
Christian Graus15-Jun-08 15:17
protectorChristian Graus15-Jun-08 15:17 
GeneralRe: out variable assignment Pin
George_George15-Jun-08 15:25
George_George15-Jun-08 15:25 
GeneralRe: out variable assignment Pin
Christian Graus15-Jun-08 15:27
protectorChristian Graus15-Jun-08 15:27 
GeneralRe: out variable assignment Pin
George_George15-Jun-08 15:49
George_George15-Jun-08 15:49 
GeneralRe: out variable assignment Pin
S. Senthil Kumar15-Jun-08 18:16
S. Senthil Kumar15-Jun-08 18:16 
GeneralRe: out variable assignment Pin
George_George15-Jun-08 18:51
George_George15-Jun-08 18:51 
GeneralRe: out variable assignment Pin
S. Senthil Kumar15-Jun-08 19:03
S. Senthil Kumar15-Jun-08 19:03 
GeneralRe: out variable assignment Pin
George_George15-Jun-08 19:14
George_George15-Jun-08 19:14 
GeneralRe: out variable assignment Pin
S. Senthil Kumar15-Jun-08 19:34
S. Senthil Kumar15-Jun-08 19:34 
GeneralRe: out variable assignment Pin
George_George15-Jun-08 19:38
George_George15-Jun-08 19:38 
AnswerRe: out variable assignment Pin
leppie15-Jun-08 19:06
leppie15-Jun-08 19:06 
QuestionSend Keys from WebApp to WinForms Pin
willybt8815-Jun-08 12:48
willybt8815-Jun-08 12:48 
AnswerRe: Send Keys from WebApp to WinForms Pin
Christian Graus15-Jun-08 12:58
protectorChristian Graus15-Jun-08 12:58 
Questionsimple regular expression problem Pin
Stephen Po15-Jun-08 11:55
Stephen Po15-Jun-08 11:55 
AnswerRe: simple regular expression problem Pin
Christian Graus15-Jun-08 12:09
protectorChristian Graus15-Jun-08 12:09 
QuestionProblem to Send Message to other Clients via MSMQ [modified] Pin
hdv21215-Jun-08 11:15
hdv21215-Jun-08 11:15 
QuestionGraphicsPath remove or alter line Pin
Chris Copeland15-Jun-08 11:13
mveChris Copeland15-Jun-08 11:13 
Hey.

I've been trying to get this to work but with no avail. I'm trying to modify a GraphicsPath to remove a line or move it so it matches the situation i'm using.

I'm using it as part of a new Rendering mode (for the ToolStripManager.Renderer), and i've got a code that creates a path (and adds curves to the corners if I want it to).

My code gets the GraphicsPath of the AffectedArea of a MenuStrip dropdown (or ToolStripDropDownButton). I want the code to remove or alter the line to leave a space for the ConnectedArea section.

Here's a picture of the area, I mean, that I want to be able to remove (opens in new window)

The black border is the GraphicsPath lines that the code retrieves. The red part is the part of the line I want to remove.

Here's a sample of the code inside OnRenderToolStripBorder(ToolStripRenderEventArgs e)

if (e.ToolStrip is ContextMenuStrip || e.ToolStrip is ToolStripDropDownMenu)
{
	Rectangle Area = new Rectangle(0, 0, e.AffectedBounds.Width - 1, e.AffectedBounds.Height - 1);

	e.Graphics.SmoothingMode = SmoothingMode.AntiAlias;

	using (GraphicsPath Path = CreateDrawingPath(Area, 0))
	{
		e.Graphics.DrawPath(Pens.Black, Path);
	}
}


I've tried using:

Path.PathPoints[0] = new PointF(e.ConnectedArea.Width, 0);


To try and change the first point of the GraphicsPath to start from the X axis of the width of the ConnectedArea (the GraphicsPath goes "Left-top" -> "Right-top", "Right-top" -> "Right-bottom" etc).

But it doesn't work. Does anyone have an idea how I might be able to move the first point to where the ConnectedArea Width ends?

Thanks in advance Smile | :)
QuestionConverting a project to .Net 3 Pin
Muammar©15-Jun-08 9:28
Muammar©15-Jun-08 9:28 
AnswerRe: Converting a project to .Net 3 Pin
Christian Graus15-Jun-08 9:32
protectorChristian Graus15-Jun-08 9:32 
GeneralRe: Converting a project to .Net 3 Pin
Muammar©15-Jun-08 9:37
Muammar©15-Jun-08 9:37 
GeneralRe: Converting a project to .Net 3 Pin
Christian Graus15-Jun-08 9:43
protectorChristian Graus15-Jun-08 9:43 
GeneralRe: Converting a project to .Net 3 Pin
Muammar©15-Jun-08 9:49
Muammar©15-Jun-08 9:49 
GeneralRe: Converting a project to .Net 3 Pin
Christian Graus15-Jun-08 9:52
protectorChristian Graus15-Jun-08 9:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.