Click here to Skip to main content
15,901,284 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
AnswerRe: Non static class with only static methods Pin
Bernhard Hiller2-Mar-11 3:01
Bernhard Hiller2-Mar-11 3:01 
AnswerRe: Non static class with only static methods Pin
Gregory Gadow4-Mar-11 4:06
Gregory Gadow4-Mar-11 4:06 
GeneralRe: Non static class with only static methods Pin
Karthik. A4-Mar-11 4:16
Karthik. A4-Mar-11 4:16 
GeneralRe: Non static class with only static methods Pin
Gregory Gadow4-Mar-11 6:53
Gregory Gadow4-Mar-11 6:53 
GeneralRe: Non static class with only static methods Pin
Karthik. A4-Mar-11 7:54
Karthik. A4-Mar-11 7:54 
AnswerRe: Non static class with only static methods Pin
Karthik. A4-Mar-11 4:14
Karthik. A4-Mar-11 4:14 
QuestionUrl Image Path in WPF Pin
Pranit Kothari1-Mar-11 8:03
Pranit Kothari1-Mar-11 8:03 
AnswerRe: Url Image Path in WPF Pin
Pete O'Hanlon1-Mar-11 8:54
mvePete O'Hanlon1-Mar-11 8:54 
If you're binding to the image from something like a VM, you need to read the image in first. The easiest way to do this is to use something like this:
C#
public BitmapImage TheImage
{
  get
  {
    return LoadImageFromSource();
  }
}

private BitmapImage LoadImageFromSource()
{
  BitmapImage image = new BitmapImage();

  try
  {
    image.BeginInit();
    image.CacheOption = BitmapCacheOption.OnLoad;
    image.CreateOptions = BitmapCreateOptions.IgnoreImageCache;
    image.UriSource = new Uri( FullPath, UriKind.Absolute );
    image.EndInit();
  }
  catch{
    return DependencyProperty.UnsetValue;
  }
  return image;
}

I'm not a stalker, I just know things. Oh by the way, you're out of milk.

Forgive your enemies - it messes with their heads


My blog | My articles | MoXAML PowerToys | Onyx


AnswerRe: Url Image Path in WPF Pin
Pete O'Hanlon1-Mar-11 9:25
mvePete O'Hanlon1-Mar-11 9:25 
QuestionNot able to see my yesterday's question and replies Pin
sr15928-Feb-11 19:46
sr15928-Feb-11 19:46 
AnswerRe: Not able to see my yesterday's question and replies Pin
RobCroll28-Feb-11 21:45
RobCroll28-Feb-11 21:45 
AnswerRe: Not able to see my yesterday's question and replies Pin
Eddy Vluggen28-Feb-11 23:09
professionalEddy Vluggen28-Feb-11 23:09 
AnswerRe: Not able to see my yesterday's question and replies Pin
Abhinav S1-Mar-11 1:02
Abhinav S1-Mar-11 1:02 
QuestionAdding layers Pin
Sander Rossel25-Feb-11 8:19
professionalSander Rossel25-Feb-11 8:19 
AnswerRe: Adding layers Pin
Not Active25-Feb-11 10:23
mentorNot Active25-Feb-11 10:23 
GeneralRe: Adding layers Pin
Sander Rossel25-Feb-11 12:44
professionalSander Rossel25-Feb-11 12:44 
GeneralRe: Adding layers Pin
Not Active25-Feb-11 13:43
mentorNot Active25-Feb-11 13:43 
GeneralRe: Adding layers Pin
Sander Rossel25-Feb-11 22:20
professionalSander Rossel25-Feb-11 22:20 
GeneralRe: Adding layers Pin
jschell26-Feb-11 13:49
jschell26-Feb-11 13:49 
AnswerRe: Adding layers Pin
Eddy Vluggen25-Feb-11 23:02
professionalEddy Vluggen25-Feb-11 23:02 
GeneralRe: Adding layers Pin
Sander Rossel26-Feb-11 1:03
professionalSander Rossel26-Feb-11 1:03 
GeneralRe: Adding layers Pin
Eddy Vluggen26-Feb-11 6:01
professionalEddy Vluggen26-Feb-11 6:01 
AnswerRe: Adding layers Pin
Richard MacCutchan25-Feb-11 23:13
mveRichard MacCutchan25-Feb-11 23:13 
GeneralRe: Adding layers Pin
Sander Rossel26-Feb-11 1:05
professionalSander Rossel26-Feb-11 1:05 
GeneralRe: Adding layers Pin
Richard MacCutchan26-Feb-11 2:18
mveRichard MacCutchan26-Feb-11 2:18 

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.