Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7715505
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T02:24:09+00:00 2026-06-01T02:24:09+00:00

I have a stupid WinCE application where I’m just trying to force an exception

  • 0

I have a stupid WinCE application where I’m just trying to force an exception and get the exception message to be retrieved from the System.SR.dll which gets deployed to the device.

The code that I have throwing an exception is the following:

TcpClient client = new TcpClient("abcd", 1234);

But when the SocketException tries to resolve it’s message, it throws a FileNotFoundException with the following tacktrace:

at System.Reflection.Assembly.InternalGetSatelliteAssembly()
at System.Reflection.Assembly.GetSatelliteAssembly()
at System.Resources.ResourceManager.InternalGetResourceSet()
at System.Resources.ResourceManager.GetString()
at System.Resources.ResourceManager.GetString()
at System.SRSupport.HasString()
at System.SRSupport.HasString()
at System.SR.HasString()
at System.Net.Sockets.SocketException.makeMessage()
at System.Net.Sockets.SocketException..ctor()
at System.Net.Dns.ResolveInternal()
at System.Net.Dns.GetHostEntry()
at System.Net.Sockets.TcpClient.Connect()
at System.Net.Sockets.TcpClient..ctor()
at WinCeMessage.Com.SocketBlaster.Blast()
at WinCeMessage.Form1.button1_Click()
at System.Windows.Forms.Control.OnClick()
at System.Windows.Forms.Button.OnClick()
at System.Windows.Forms.ButtonBase.WnProc()
at System.Windows.Forms.Control._InternalWnProc()
at Microsoft.AGL.Forms.EVL.EnterMainLoop()
at System.Windows.Forms.Application.Run()
at WinCeMessage.Program.Main()

(I believe) The file where these messages are kept is the System.SR.dll, which gets deployed to the device when I run it in Visual Studio. I docked the emulator, and verified that file is present.

This is the code from System.SR.dll throwing the exception:

internal Assembly InternalGetSatelliteAssembly(CultureInfo culture, Version version, bool throwOnFileNotFound)
{
    if (culture != null)
    {
        Assembly assembly = null;
        AssemblyName name = this.GetName();
        if (name != null)
        {
            name.Version = version;
            name.CultureInfo = culture;
            if (name.Name != null)
            {
                name.Name = string.Concat(name.Name, ".resources");
                name.CodeBase = null;
            }
            try
            {
                StackCrawlMark stackCrawlMark = StackCrawlMark.LookForMyCaller;
                assembly = Assembly.BCL_System_Reflection_Assembly_LoadFromName(name, false, null, ref stackCrawlMark);
            }
            catch (IOException oException)
            {
                assembly = null;
            }
            if (assembly != null)
            {
                if (assembly == this)
                {
                    if (!throwOnFileNotFound)
                    {
                        return null;
                    }
                    else
                    {
                        throw new FileNotFoundException();
                    }
                }
            }
            else
            {
                if (!throwOnFileNotFound)
                {
                    return null;
                }
                else
                {
                    throw new FileNotFoundException();
                }
            }
        }
        return assembly;
    }
    else
    {
        throw new ArgumentNullException();
    }
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T02:24:10+00:00Added an answer on June 1, 2026 at 2:24 am

    I ended up making a new solution, that one seemed broken for some reason.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a stupid python problem. I'm trying to read a line from a
I just started learning Objective-C and OOP ... so I have very stupid question
I have a stupid java logging problem: I'm loading the logging configuration from my
I have stupid question, sometime you just go on and design something and do
I have this stupid problem. I bind from view model class property type of
Maybe i have some stupid questions about mysql_insert_id... I need to get the last
I have a stupid idea. With android is simple to get battery state (volt,
I have a probably stupid problem. Im trying to iterate through the vertices of
I have stupid problem with pow() in my application. Here is the code: double
I have a stupid problem here. I'm developing a web application with ASP .NET

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.