cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Add menu to Pro/E menu bar in WF4 64bit

ptc-161645
1-Newbie

Add menu to Pro/E menu bar in WF4 64bit

I am compiling our utilities for WF 4 for 64 bit, and I can not get one
of my toolkit dll files to load into Pro/E. The file is very simple, it
just adds a menu to the Pro/E menu bar and adds a few sub menus. When
it loads, it gives a PRO_TK_GENERAL_ERROR. I have tried everything I
can think of, including the sample code from the Pro/TK user guide and
the pt_examples included in the Pro/Toolkit install directory, and they
all give the same PRO_TK_GENERAL_ERROR error. The pt_install_test, and
one of my utilities that adds a button to an existing menu, both work
ok. Anyone have any idea on what the problem may be, or on how to debug
this?

Thanks,

Scott Edsell

TYCO Electronics

This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
3 REPLIES 3

Did you compile the application with the 64 bit target or the 32 bit
target?



Patrick Williams | Sr. Application Engineer | Engineering Systems |
Steelcase Inc. | 616.698.4078 | My Site
<">http://my.steelcase.com/Person.aspx?accountname=NA\PWILLIA3>





Patrick,
I use makefiles which are based on the sample make files.

MAKEFILENAME = makefile64

# Machine Type

PRO_MACHINE_TYPE = x86e_win64

# Executable names

EXE = TYCOmenu64.exe

EXE_DLL = TYCOmenu64.dll

# Pro/Toolkit Source & Machine Loadpoint (EXTERNAL USE - DEFAULT)

PROTOOL_SRC = C:/EngApps/PTCpro/wf4_m030_x64/protoolkit/

PROTOOL_SYS = $(PROTOOL_SRC)/$(PRO_MACHINE_TYPE)

PRODEV_SRC = C:/EngApps/PTCpro/wf4_m030_x64/prodevelop

PRODEV_SYS = $(PRODEV_SRC)/$(PRO_MACHINE_TYPE)

INCS = -I. -I$(PROTOOL_SRC)/includes \

-I$(PRODEV_SRC)/prodev_appls/includes -I$(PRODEV_SRC)/includes

# Compiler Flags

CC = cl

MACH = -DPRO_MACHINE=36 -DPRO_OS=4

CCFLAGS = -c -GS -fp:precise -D_WSTDIO_DEFINED -DAMP_PC -DREGEX_MALLOC

CFLAGS = $(CCFLAGS) $(INCS) $(MACH)



# Libraries

PTCLIBS = $(PRODEV_SYS)/obj/prodevelop.lib
$(PROTOOL_SYS)/obj/protoolkit.lib

PTCLIBS_DLL = $(PRODEV_SYS)/obj/prodev_dll.lib
$(PROTOOL_SYS)/obj/protk_dll.lib

LIBS = libcmt.lib kernel32.lib user32.lib wsock32.lib ole32.lib
advapi32.lib mpr.lib winspool.lib netapi32.lib psapi.lib gdi32.lib
shell32.lib comdlg32.lib

OBJS = TYCOmenu.obj

# Linker

LINK = link

$(EXE) : $(OBJS) $(PTCLIBS)

@echo Start at `date`

@echo PROTOOL_SRC = $(PROTOOL_SRC)

@echo PROTOOL_SYS = $(PROTOOL_SYS)

#Executable applications compiled using WinMain() instead of main()
should set the subsystem to windows instead of console.

$(LINK) /subsystem:console -out:$(EXE) /debug:none @<<longline.list<br/>
$(OBJS) $(PTCLIBS) $(LIBS)

<<

@echo Finished at `date`

del $(OBJS)

# Dll target

dll: $(EXE_DLL)

$(EXE_DLL) : $(OBJS) $(PTCLIBS_DLL)

@echo Start at `date`

@echo PROTOOL_SRC = $(PROTOOL_SRC)

@echo PROTOOL_SYS = $(PROTOOL_SYS)

$(LINK) /subsystem:console -out:$(EXE_DLL) /debug:none /dll
@<<longline.list<br/>
$(OBJS) $(PTCLIBS_DLL) $(LIBS)

<<

@echo Finished at `date`

# object dependencies

PROTK_APPLS = $(PROTOOL_SRC)/protk_appls/pt_af_examples

PROTK_UTILS = $(PROTOOL_SRC)/protk_appls/pt_examples/pt_utils

TYCOmenu.obj: TYCOmenu.c

$(CC) $(CFLAGS) TYCOmenu.c

clean :

del $(OBJS)

del $(EXE)

nmake -f $(MAKEFILENAME)

clean_dll :

del $(OBJS)

del $(EXE_DLL)

nmake -f $(MAKEFILENAME) dll

The problem was that I had installed VS 2005 SP 1 on the 64 bit system.
This is not supported, so I uninstalled and reinstalled VS 2005 and
recompiled the DLLs, and now everything is working. Thank you for all
of the replies.

Scott
Announcements
Attention: Creo 7.0 Customers
Please consider upgrading
End of Life announcement here.

NEW Creo+ Topics:
PTC Control Center
Creo+ Portal
Real-time Collaboration