Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Feature Requests
 Properties Script - Autotext/Template/ Ma
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

JoshCrosby
New Member

USA
2 Posts

Posted - Aug 18 2004 :  11:48:28 AM  Show Profile
Does anyone have or know of a way to quickly change a selection into properties for C#? example, I often will have a list of column names from a database and would like to select them and have them convert to properties either by autotext or a template or macro not really picky just lazy

i.e. list here

SiteId
FirmId
PurchaseDate
ExpirationDate

converts to

private int _SiteId;
public int SiteId {
get { return _SiteId; }
set { _SiteId = value; }
} etc.......


thanks for any help

Josh D Crosby

WannabeeDeveloper
Tomato Guru

Germany
775 Posts

Posted - Aug 18 2004 :  12:53:52 PM  Show Profile
I do not know C# and Properties, but your Code could be entered into the Autotext as follows:


Make Property using Selection:
private int _%0;
public int %0 {
    get { return _%0; }
    set { _%0 = value; }
}




Note that %0 is your selection, so you would have to select each word separately.
Was that of some help?

Go to Top of Page

JoshCrosby
New Member

USA
2 Posts

Posted - Aug 18 2004 :  2:16:40 PM  Show Profile
That may work, it would be nice to do a selection. But this is still a whole lot better than typing everything, like i said i'm lazy thanks for the info

Josh D Crosby
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000