Click here to Skip to main content
16,005,236 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Saving font parameters to a Text file Pin
militiaware29-Sep-05 14:23
militiaware29-Sep-05 14:23 
GeneralRe: Saving font parameters to a Text file Pin
PatriceB29-Sep-05 23:54
PatriceB29-Sep-05 23:54 
GeneralRe: Saving font parameters to a Text file Pin
militiaware30-Sep-05 3:50
militiaware30-Sep-05 3:50 
GeneralRe: Saving font parameters to a Text file Pin
PatriceB30-Sep-05 6:52
PatriceB30-Sep-05 6:52 
GeneralRe: Saving font parameters to a Text file Pin
rwestgraham30-Sep-05 9:46
rwestgraham30-Sep-05 9:46 
GeneralRe: Saving font parameters to a Text file Pin
PatriceB30-Sep-05 13:56
PatriceB30-Sep-05 13:56 
GeneralRe: Saving font parameters to a Text file Pin
rwestgraham30-Sep-05 15:40
rwestgraham30-Sep-05 15:40 
GeneralRe: Saving font parameters to a Text file Pin
PatriceB1-Oct-05 1:44
PatriceB1-Oct-05 1:44 
Well, saving all the font parameters looks easy to write in a single sentence:

recreate the font - Family, Style, Size, Color.

It would have been nice to have something like: ListView1.Font.ToString
ListView1.Font.FromString

What we have handy is more confusing :
assuming you have open sw as streamwriter

sw.WriteLine(ListView1.Font) writes :
[Font: Name=Times New Roman, Size=15,75, Units=3, GdiCharSet=0, GdiVerticalFont=False]

sw.WriteLine(ListView2.Font.Size) can give : 9,75 or 12

Question : how can we restore(well simply) a font size defined by : 10 12 9,75 or 15,75 ?

The only way I find is to parse the written string and analyse to look if we have a ',' in the size Confused | :confused:
and then convert it in 15.75

pfff!

Best Regards



Pat
GeneralRe: Saving font parameters to a Text file Pin
PatriceB1-Oct-05 6:12
PatriceB1-Oct-05 6:12 
GeneralRe: Saving font parameters to a Text file Pin
rwestgraham1-Oct-05 10:50
rwestgraham1-Oct-05 10:50 
QuestionPushing data to Excel Pin
Member 228077329-Sep-05 6:32
Member 228077329-Sep-05 6:32 
QuestionExport to app.config file Pin
PHDENG8129-Sep-05 6:26
PHDENG8129-Sep-05 6:26 
QuestionEfficient way to clear all controls on page Pin
jszpila29-Sep-05 6:24
jszpila29-Sep-05 6:24 
AnswerRe: Efficient way to clear all controls on page Pin
_mubashir29-Sep-05 23:12
_mubashir29-Sep-05 23:12 
GeneralRe: Efficient way to clear all controls on page Pin
jszpila30-Sep-05 4:14
jszpila30-Sep-05 4:14 
GeneralRe: Efficient way to clear all controls on page Pin
jszpila30-Sep-05 4:23
jszpila30-Sep-05 4:23 
Questioncontextmenu right click Pin
andy3829-Sep-05 6:04
andy3829-Sep-05 6:04 
QuestionVisual Basic IDE Pin
theart29-Sep-05 3:45
theart29-Sep-05 3:45 
AnswerRe: Visual Basic IDE Pin
Brian Van Beek29-Sep-05 5:17
Brian Van Beek29-Sep-05 5:17 
GeneralRe: Visual Basic IDE Pin
Anonymous29-Sep-05 22:38
Anonymous29-Sep-05 22:38 
GeneralRe: Visual Basic IDE Pin
S Douglas30-Sep-05 0:33
professionalS Douglas30-Sep-05 0:33 
QuestionExporting to XML Pin
PHDENG8129-Sep-05 2:10
PHDENG8129-Sep-05 2:10 
AnswerRe: Exporting to XML Pin
Dave Kreskowiak29-Sep-05 2:49
mveDave Kreskowiak29-Sep-05 2:49 
GeneralRe: Exporting to XML Pin
PHDENG8129-Sep-05 3:22
PHDENG8129-Sep-05 3:22 
Questioneclipse for vb.net programming Pin
chitranjan gohil28-Sep-05 23:36
chitranjan gohil28-Sep-05 23:36 

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.