Codejock Shortcutbar
Codejock Shortcutbar
Hi all,
anybody using Codejock Shortcutbar out there ?
Donnay sample on this control gives error at compilation. I use Xbase++ 1.9 SL1 and express 257.
Thanks
Joe
anybody using Codejock Shortcutbar out there ?
Donnay sample on this control gives error at compilation. I use Xbase++ 1.9 SL1 and express 257.
Thanks
Joe
Re: Codejock Shortcutbar
Hi,
I tried it in the past. Better solution is to look at the samples pbstack and outlookbar in the samples. This is pure eXPress++ and works without a problem.
I tried it in the past. Better solution is to look at the samples pbstack and outlookbar in the samples. This is pure eXPress++ and works without a problem.
Re: Codejock Shortcutbar
Hi, Joe.
You need to place the version number of the Codejock installation you have in there, around line 17:
You can retrieve the version number by checking the names of the OCX files. It's at the end, right before the suffix.
This is what you should get then:
You need to place the version number of the Codejock installation you have in there, around line 17:
Code: Select all
#define shortcutbarCLSID 'Codejock.ShortCutBar.a.b.c' // a.b.c is your version number, like 14.0.0
This is what you should get then:
- Attachments
-
- shortcut.jpg (71.71 KiB) Viewed 15596 times
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: Codejock Shortcutbar
Hi Tom
Please send post your sample code for me.
Joe
Please send post your sample code for me.
Joe
Re: Codejock Shortcutbar
Hi, Joe.
It's "MAIN.PRG" from <eXpressInstallation>\Samples\Codjock\Shortcutbar.
It's "MAIN.PRG" from <eXpressInstallation>\Samples\Codjock\Shortcutbar.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: Codejock Shortcutbar
Thanks Tom,
There is another sample under xcodejock\samples folder that is not working, that was the one I was looking into.
Joe.
There is another sample under xcodejock\samples folder that is not working, that was the one I was looking into.
Joe.
Re: Codejock Shortcutbar
Hi, Joe.
Got it.
Put this code in there, right at the beginning of "main", behind the definition of the locals:
Got it.
Put this code in there, right at the beginning of "main", behind the definition of the locals:
Code: Select all
CJ_Version('a.b.c') // i.e. CJ_Version('14.0.0')
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: Codejock Shortcutbar
Add: XCodejock needs to know the version number of the Codejock installation you have - and all samples aswell. One way to acchieve this is to set an environment var which contains the number: SET CODEJOCK VERSION=a.b.c. Remember Windows 7 and higher will not create persistent environment vars if you do this at the command prompt or in an AUTOEXEC file, so you need to put this into the registry, otherwise it will be left if you close the command prompt. All samples should run then, without recompiling. A little more elegant is to set the version number inside the code, which will guarantee the execution of your apps at the customer's sites.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: Codejock Shortcutbar
CJshortcutbarLoadBitMap command accept <cFilename.bmp> , any function to convert a resource ID to a <cFilename.bmp> for this command ?
Thanks.
Joe
Thanks.
Joe
Re: Codejock Shortcutbar
Codejock does have Imagelist where you can load from Resource.unixkd wrote:CJshortcutbarLoadBitMap command accept <cFilename.bmp> , any function to convert a resource ID to a <cFilename.bmp> for this command ?
Code: Select all
::oImageList := XbpActiveXControl():new( ::drawingArea, , { 0, 0}, { 0, 0} )
*d*::oImageList:CLSID := "{8ACA76B7-6CF3-4344-9686-6110DCDEA99A}"
::oImageList:CLSID := "Codejock.ImageManager"+HX_VERSION()
::oImageList:create()
remember Icon most have different Size-Icon-Set and are better for resize than single Bitmap with fixed Size
Code: Select all
METHOD VOBWORK:InitImgList()
LOCAL i,iMax
LOCAL nHandle
LOCAL oIcons
LOCAL nResource
LOCAL nCommand
LOCAL aIcon := ICON2DIM()
//
// now load Icon from Resource DLL
//
nHandle := GetModuleHandleA( "MyResource.DLL" )
//
// get Property "Icons" from Codejock.ImageManager
//
oIcons := ::oImageList:getProperty("Icons")
iMax := LEN(aIcon)
FOR i := 1 TO iMax
nResource := aIcon[i,2] // using #define ID_FILE_NEW
nCommand := aIcon[i,2] // both are the same
oIcons:LoadIconFromResource( nHandle ,; // handle for Resource DLL
nResource ,; // Specifies the image to load in the resources of the module.
nCommand ,; // The id that will be used to identify the icon in the collection
xtpImageNormal ) // of icons.
NEXT
IF ::oImageList:Icons:Count() == 0
MSGBOX("Icons "+LTRIM(STR(::oImageList:Icons:Count()))+" can not continue with ICON")
ENDIF
RETURN self
Code: Select all
::oShortGlob := CreateObject( "Codejock.ShortcutBarGlobalSettings"+HX_VERSION() )
::oShortGlob:Office2007Images := zPath+"Styles\"+"Office2007Blue.dll"
::oShortGlob:ResourceFile := zPath+"Styles\"+"SuitePro.ResourceDe.dll"
::oShortCut := XbpActiveXControl():new( ::drawingArea,, aPos,aSize )
* ::oShortCut:CLSID := "{F791DF43-12A6-4C5B-AE46-671E888FD79F}"
::oShortCut:CLSID := "Codejock.ShortcutBar"+HX_VERSION()
::oShortCut:License := "..."
::oShortCut:UserEvents := .F.
::oShortCut:create()
::oShortCap := XbpActiveXControl():new( ::drawingArea,, aPos,{0,0} )
* ::oShortCap:CLSID := "{FF5A8E61-133A-4C43-BE5D-732D3F6CCCFB}"
::oShortCap:CLSID := "Codejock.ShortcutCaption"+HX_VERSION()
::oShortCap:License := "..."
::oShortCap:UserEvents := .F.
::oShortCap:create()
::oShortCut:VisualTheme := xtpShortcutThemeOffice2007
::oShortCut:Icons := ::oImageList:Icons
::oShortCut:Item(0):IconId := ID_CALENDAR
::oShortCut:Item(1):IconId := ID_ERFASSUNG
::oShortCut:Item(2):IconId := ID_ARBEIT
::oShortCut:Item(3):IconId := ID_FAKTURA
::oShortCut:Item(4):IconId := ID_KUNDEN
::oShortCut:Item(5):IconId := ID_IMOBILIE
::oShortCut:Item(6):IconId := ID_ARTIKEL
::oShortCut:Item(7):IconId := ID_UMSATZ
::oShortCut:Item(8):IconId := ID_TOOLS
greetings by OHR
Jimmy
Jimmy