ref class and ref struct are the same thing. You could replace class with struct below, but no-one uses struct.

Define a structure

	public ref class DOCINFO
	{
	public:
		String ^DocumentName;
		String ^OutputFile;
		int ^TheValue;
	};
If You Need A Constructor

		//----- CONSTRUCTOR -----
		public: DOCINFO::DOCINFO()
		{
			DocumentName = "";
			OutputFile = "";
		}
Use it in functions

	void MyFunction (DOCINFO ^info)
	{
		info->DocumentName = "Hello";
		int->TheValue = 10;

or


	void MyFunction (DOCINFO info)
	{
		info.DocumentName = "Hello";
		int.TheValue = 10;
Define it in functions

	DOCINFO ^info;

	info->DocumentName = "Hello";
	int->TheValue = 10;

or


	DOCINFO info;

	info.DocumentName = "Hello";
	int.TheValue = 10;
USEFUL?
We benefit hugely from resources on the web so we decided we should try and give back some of our knowledge and resources to the community by opening up many of our company’s internal notes and libraries through mini sites like this. We hope you find the site helpful.
Please feel free to comment if you can add help to this page or point out issues and solutions you have found, but please note that we do not provide support on this site. If you need help with a problem please use one of the many online forums.