Click here to Skip to main content
15,887,175 members
Home / Discussions / C#
   

C#

 
GeneralRe: Basic Question: Conversion Pin
Saksida Bojan30-Nov-09 8:44
Saksida Bojan30-Nov-09 8:44 
GeneralRe: Basic Question: Conversion Pin
PIEBALDconsult30-Nov-09 9:12
mvePIEBALDconsult30-Nov-09 9:12 
GeneralRe: Basic Question: Conversion Pin
Saksida Bojan30-Nov-09 10:05
Saksida Bojan30-Nov-09 10:05 
GeneralRe: Basic Question: Conversion Pin
ThatsAlok30-Nov-09 22:49
ThatsAlok30-Nov-09 22:49 
QuestionMCV Pattern in 2 threads for GUI and Worker ? Pin
User 260419330-Nov-09 6:33
User 260419330-Nov-09 6:33 
AnswerRe: MCV Pattern in 2 threads for GUI and Worker ? Pin
Luc Pattyn30-Nov-09 6:38
sitebuilderLuc Pattyn30-Nov-09 6:38 
QuestionI need help - problem with query builder in c# Pin
TGiril30-Nov-09 6:26
TGiril30-Nov-09 6:26 
QuestionPlease help. Printing datagridview issue... Pin
JollyMansArt30-Nov-09 5:11
JollyMansArt30-Nov-09 5:11 
I have learned a lot doing this project with datagrid views. But I have one issue though minor to me is a major issue to the client. I have been working on this for over 2 weeks and can not find any examples to give me the output I am looking for.

Please Help any Ideas please:

What I need to be able to do is essentially print my database grid column header names vertically at a 90.0F angle. Not horizontally as the default.
I have learned how to do this to the grid itself so it prints correctly on the screen. Which is:
private void dgvReport_CellPainting(object sender, DataGridViewCellPaintingEventArgs e)
        {
            
            if (e.RowIndex == -1 && e.ColumnIndex >= 4)
            {
                e.PaintBackground(e.ClipBounds, true);
                Rectangle rect = 
                    this.dgvReport.GetColumnDisplayRectangle(e.ColumnIndex, true);
                Size titleSize =
                    TextRenderer.MeasureText(e.Value.ToString(), e.CellStyle.Font);
                if (this.dgvReport.ColumnHeadersHeight < titleSize.Width)
                    this.dgvReport.ColumnHeadersHeight = titleSize.Width;

                e.Graphics.TranslateTransform(0, titleSize.Width);
                e.Graphics.RotateTransform(-90.0F);

                e.Graphics.DrawString(e.Value.ToString(), e.CellStyle.Font, //this.Font,
                    Brushes.Black, new PointF(rect.Y, rect.X));

                e.Graphics.RotateTransform(90.0F);
                e.Graphics.TranslateTransform(0, -titleSize.Width);
                e.Handled = true;
            } 
            
        }


But When I send the grid to the printer the columns are all horizontal not vertical. What can I do to print the columns vertical. Any examples anywhere?
AnswerRe: Please help. Printing datagridview issue... Pin
JollyMansArt30-Nov-09 11:23
JollyMansArt30-Nov-09 11:23 
QuestionRegex question Pin
kanchoette30-Nov-09 4:28
kanchoette30-Nov-09 4:28 
AnswerRe: Regex question Pin
OriginalGriff30-Nov-09 4:47
mveOriginalGriff30-Nov-09 4:47 
AnswerRe: Regex question PinPopular
PIEBALDconsult30-Nov-09 4:58
mvePIEBALDconsult30-Nov-09 4:58 
QuestionHow to Get the MSI installer Path Pin
coolpjmartin30-Nov-09 4:27
coolpjmartin30-Nov-09 4:27 
AnswerRe: How to Get the MSI installer Path Pin
The Man from U.N.C.L.E.30-Nov-09 7:43
The Man from U.N.C.L.E.30-Nov-09 7:43 
Questionregular expression in c# [modified] Pin
benjamin yap30-Nov-09 1:29
benjamin yap30-Nov-09 1:29 
AnswerRe: regular expression in c# Pin
vivasaayi30-Nov-09 2:07
vivasaayi30-Nov-09 2:07 
AnswerRe: regular expression in c# Pin
PIEBALDconsult30-Nov-09 5:06
mvePIEBALDconsult30-Nov-09 5:06 
QuestionPlay one or more files in single execution Pin
yesu prakash30-Nov-09 1:28
yesu prakash30-Nov-09 1:28 
AnswerRe: Play one or more files in single execution Pin
Covean30-Nov-09 1:52
Covean30-Nov-09 1:52 
AnswerRe: Play one or more files in single execution Pin
souidi abderrahman30-Nov-09 3:24
souidi abderrahman30-Nov-09 3:24 
QuestionSpeech Recognition using .net framework 3.5 Pin
krinaljariwala30-Nov-09 1:04
krinaljariwala30-Nov-09 1:04 
AnswerRe: Speech Recognition using .net framework 3.5 Pin
Abhishek Sur30-Nov-09 1:31
professionalAbhishek Sur30-Nov-09 1:31 
GeneralRe: Speech Recognition using .net framework 3.5 Pin
krinaljariwala30-Nov-09 1:44
krinaljariwala30-Nov-09 1:44 
GeneralRe: Speech Recognition using .net framework 3.5 Pin
Abhishek Sur30-Nov-09 2:09
professionalAbhishek Sur30-Nov-09 2:09 
QuestionSetting DataGridView ColumnHeader text Pin
kanchoette30-Nov-09 0:50
kanchoette30-Nov-09 0:50 

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.