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

  • Home
  • SEARCH
  • 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 3605922
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T21:11:03+00:00 2026-05-18T21:11:03+00:00

I have a dictionary like the follow: public Dictionary<int, SpawnList> spawnEntities = new Dictionary<int,

  • 0

I have a dictionary like the follow:

public Dictionary<int, SpawnList> spawnEntities = new Dictionary<int, SpawnList>();

The class being used is as follow:

    public class SpawnList
    {
        public int NpcID { get; set; }
        public string Name { get; set; }
        public int Level { get; set; }
        public int TitleID { get; set; }
        public int StaticID { get; set; }

        public entityType Status { get; set; }

        public int TypeA { get; set; }
        public int TypeB { get; set; }
        public int TypeC { get; set; }

        public int ZoneID { get; set; }
        public int Heading { get; set; }
        public float PosX { get; set; }
        public float PosY { get; set; }
        public float PosZ { get; set; }
    }

/// <summary>Entity type enum.</summary>
public enum entityType
{
    Ally,
    Enemy,
    SummonPet,
    NPC,
    Object,
    Monster,
    Gatherable,
    Unknown
}
  • How could I save this Dictionary to
    either a binary or encrypted format
    so I could later Load it again into
    my application ?

    My biggest problem here is not on how to save the file it self or encrypt it but mostly on how to do it when you have a class with it and how you go about deserializing it later.

My limitation is .Net 3.5 can’t use anything higher.

  • 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-05-18T21:11:03+00:00Added an answer on May 18, 2026 at 9:11 pm

    The easy way to get you started:

    1. Make your class serializable by attaching the [Serializable] attribute.
    2. Use CryptoStream and BinaryFormatter to serialize it into a file and encrypt the data.

    The reference for CryptoStream provides a complete example for setting up encryption and doing the related file handling.

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

Sidebar

Related Questions

I have a 'matrix' object like follows: public class Matrix { public Dictionary<string, string>
Suppose I have a Dictionary like so: Dictionary<string, Stream> How can I get a
I have dictionary, like Dictionary<string, bool> accValues = new Dictionary<string, bool>() And I want
When I have a Dictionary<string, int> actual and then create a completely new Dictionary<string,
I have code that has a Dictionary defined as: Dictionary<int, StringBuilder> invoiceDict = new
I have a dictionary like this: /// <summary> /// Gets the leave entitlement details.
I have a string like string strn = abcdefghjiklmnopqrstuvwxyz and want a dictionary like:
Does VBA have dictionary structure? Like key<>value array?
I have a dictionary object which i would like to encrypt, then put it
I have passed to template dictionary parameters like parameters={ 'value':'some_value', 'style':{} } and inside

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.