Click here to Skip to main content
15,888,351 members
Home / Discussions / C#
   

C#

 
GeneralRe: Can you target .NET and .NET CF from one project? Pin
hairy_hats3-Mar-10 6:56
hairy_hats3-Mar-10 6:56 
GeneralRe: Can you target .NET and .NET CF from one project? Pin
Som Shekhar3-Mar-10 7:01
Som Shekhar3-Mar-10 7:01 
GeneralRe: Can you target .NET and .NET CF from one project? Pin
Dave Kreskowiak3-Mar-10 8:36
mveDave Kreskowiak3-Mar-10 8:36 
GeneralRe: Can you target .NET and .NET CF from one project? Pin
hairy_hats3-Mar-10 11:01
hairy_hats3-Mar-10 11:01 
GeneralRe: Can you target .NET and .NET CF from one project? Pin
Dave Kreskowiak3-Mar-10 11:53
mveDave Kreskowiak3-Mar-10 11:53 
QuestionCreating graphics object Pin
gwithey3-Mar-10 4:09
gwithey3-Mar-10 4:09 
AnswerRe: Creating graphics object Pin
kevinnicol3-Mar-10 4:21
kevinnicol3-Mar-10 4:21 
GeneralRe: Creating graphics object Pin
gwithey3-Mar-10 4:28
gwithey3-Mar-10 4:28 
Thank you Kevinnicol

That worked great, i was looking for something like that.


public static SizeF MeasureString(string s, Font font)
   {
       SizeF result;
       using (var image = new Bitmap(0, 0))
       {
           using (var g = Graphics.FromImage(image))
           {
               result = g.MeasureString(s, font);
           }
       }

       return result;
   }


Did see this example but preffer the below:
// Generate nodeSize by measuring the name of the node
        Graphics g = Graphics.FromImage(new Bitmap(80, 80));
        m_nodeSize = g.MeasureString(m_name, nodeFont);


Thanx George
GeneralRe: Creating graphics object Pin
Pete O'Hanlon3-Mar-10 4:51
mvePete O'Hanlon3-Mar-10 4:51 
AnswerMessage Closed Pin
3-Mar-10 4:27
stancrm3-Mar-10 4:27 
GeneralRe: Creating graphics object Pin
gwithey3-Mar-10 4:31
gwithey3-Mar-10 4:31 
QuestionWeb Service Threading and State Pin
il_manti3-Mar-10 4:02
il_manti3-Mar-10 4:02 
QuestionInstaller Pin
Syed Shahid Hussain3-Mar-10 1:12
Syed Shahid Hussain3-Mar-10 1:12 
AnswerRe: Installer Pin
Richard Andrew x643-Mar-10 8:18
professionalRichard Andrew x643-Mar-10 8:18 
QuestionDifference between where<>() and where() in linq? [modified] Pin
sri_34643-Mar-10 0:29
sri_34643-Mar-10 0:29 
AnswerRe: Difference between where() and where() in linq? Pin
Pete O'Hanlon3-Mar-10 1:30
mvePete O'Hanlon3-Mar-10 1:30 
AnswerRe: Difference between where() and where() in linq? Pin
Scott Dorman3-Mar-10 6:47
professionalScott Dorman3-Mar-10 6:47 
GeneralRe: Difference between where() and where() in linq? Pin
Pete O'Hanlon3-Mar-10 9:44
mvePete O'Hanlon3-Mar-10 9:44 
GeneralRe: Difference between where() and where() in linq? Pin
Scott Dorman3-Mar-10 12:41
professionalScott Dorman3-Mar-10 12:41 
GeneralRe: Difference between where() and where() in linq? Pin
Pete O'Hanlon3-Mar-10 21:41
mvePete O'Hanlon3-Mar-10 21:41 
GeneralRe: Difference between where() and where() in linq? Pin
Scott Dorman4-Mar-10 4:25
professionalScott Dorman4-Mar-10 4:25 
QuestionWeb Service web.config variables from dll in bin folder Pin
BASONJS2-Mar-10 23:39
BASONJS2-Mar-10 23:39 
QuestionHow to send commands to a running application from the command line? Pin
Ted On The Net2-Mar-10 22:43
Ted On The Net2-Mar-10 22:43 
AnswerRe: How to send commands to a running application from the command line? Pin
Eddy Vluggen2-Mar-10 23:35
professionalEddy Vluggen2-Mar-10 23:35 
GeneralRe: How to send commands to a running application from the command line? Pin
Ted On The Net2-Mar-10 23:42
Ted On The Net2-Mar-10 23:42 

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.