make a .resx file : ResXResourceWriter : GUI Windows Form C# Source Code


Custom Search

C# Source Code » GUI Windows Form » ResXResourceWriter »

 

make a .resx file








    

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Resources;


public class MainClass {
    public static void Main() {
        ResXResourceWriter w = new ResXResourceWriter(@"C:\ResXForm.resx");
        Image i = new Bitmap("happyDude.bmp");
        w.AddResource("happyDude", i);
        w.AddResource("welcomeString", "Hello new resource format!");

        w.Generate();
        w.Close();

        // Make a new *.resources file.
        ResourceWriter rw = new ResourceWriter(@"C:\myResources.resources");

        // Add 1 image and 1 string.
        rw.AddResource("happyDude", new Bitmap("happyDude.bmp"));
        rw.AddResource("welcomeString", "Hello new resource format!");
        rw.Generate();
        rw.Close();
    }
}
           
       
    
   
  
   







HTML code for linking to this page:

Follow Navioo On Twitter

C# Source Code

 Navioo GUI Windows Form
» ResXResourceWriter