SweetScape Knowledgebase
KB1036: How do I define a struct that moves with the cursor?

There are two options here. The first is to use the statement 'FSeek(GetCursorPos());' in your template before you define your structure. For example:

     FSeek(GetCursorPos());
     SetBackColor( cLtAqua );
     struct MYSTRUCT
     {
         int id;
         int value;
     } data;
     SetBackColor( cNone );

This structure also has a background color so its easier to tell where the structure is placed in your file. To move the structure, move your cursor in the file and then press the F5 key to re-run the template.

The alternate way is to run a Template on your file that contains the structs you want to use. Then you can create a custom bookmark using the types from that template (see KB1020 for more information). When you create the bookmark, make sure the Move Bookmark with Cursor toggle is enabled in the Add Bookmark dialog. After the bookmark is created, moving your cursor around the file will cause the struct to be moved with your cursor.



Back to knowledgebase index
Back to main support page




Our Products


Latest News
Download
- 010 Editor
v3.1.2
is now available.
Download it now!
What's New in 3.1.2?


Newsletter
Join our newsletter to receive tips and tricks on hex editing, special offers, and news from SweetScape Software.

Sign-up Now...





SweetScape Software
148 Pownal Rd. RR#1
Pownal, PEI
C0A 1Z0, Canada

E-mail: