How can I disable the snaplines, when I move controls using the mouse in windows forms designer, which is shown in the image:
Disable Snaplines in Windows Froms Designer
Asked Answered
bluemediaboutique.wordpress.com/tag/eric-burke –
Grandiloquent
Temporarily disable Snaplines while moving a control
Press and hold Alt key during moving the control.
Permanently disable Snaplines
You can switch to snap to grid mode and then disable snap to grid.
- Open Options from
Tool -> Options
menu - Select
Windows Forms Designer -> General
from the left-side tree view - Set
LayoutMode
toSnapToGrid
- Set
SnapToGrid
toFalse
Then press OK
, and close the designer and reopen it to apply changes.
Also you can set ShowGrid
to False
to disable showing the grid.
More information:
This is a designer setting. –
Catercorner
i am using above setting in my visual studio but it is not working –
Biocatalyst
Close all designers and then reopen them. It is tested and works properly :) –
Catercorner
I have applied but it is not working. When we hold the alt key It works but in designer window setting it not works. –
Biocatalyst
How can i set it using the C# code Please suggest me –
Biocatalyst
I think if you want to have a Custom control with custom snaplines or without snaplines, you should ask a new question. Also if you are looking for the way of creating an extension for visual studio that performs this job (While I think it's useless) you should ask a new question. –
Catercorner
This post answers Disable Snaplines in Windows Froms Designer –
Catercorner
Yes, Reza Aghaei , I have Custom Form with Custom Controls using infagistic dlls –
Biocatalyst
So you don't need to do anything else than what the answer says :) –
Catercorner
© 2022 - 2024 — McMap. All rights reserved.