NO

Author Topic: Indent Add-in  (Read 3668 times)

Offline Robert

  • Member
  • *
  • Posts: 247
Indent Add-in
« on: October 10, 2005, 04:49:14 AM »
Holger Buick's Indent Addin is not adding a command button to the Toolbar.

Robert Wishlaw

Offline Robert

  • Member
  • *
  • Posts: 247
Indent AddIn
« Reply #1 on: October 10, 2005, 05:03:27 AM »
The original DLL distributed in the indent1.0.1.zip does work.

A new DLL compiled from the .ppj with Pelle's C 4.0 does not work.

Robert Wishlaw

Offline TimoVJL

  • Global Moderator
  • Member
  • *****
  • Posts: 2115
Indent Add-in
« Reply #2 on: October 10, 2005, 06:11:47 PM »
Add-In API have changed little.
Add that AddCmd.idMenu

Code: [Select]

AddCmd.id = ID_INDENT;
AddCmd.idMenu = AIM_MENU_NOTHING; // Toolbar button
return AddIn_AddCommand(hwnd, &AddCmd);
May the source be with you

Offline Pelle

  • Administrator
  • Member
  • *****
  • Posts: 2266
    • http://www.smorgasbordet.com
Indent Add-in
« Reply #3 on: October 10, 2005, 08:37:05 PM »
The best generic solution is probably to clear all structures before they are used:

for example, change:
Code: [Select]
ADDIN_ADD_COMMAND AddCmd;
to:
Code: [Select]
ADDIN_ADD_COMMAND AddCmd = {0};

Zero or NULL are the default for fields added after the initial release...

Pelle
/Pelle