Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Customizing ACCPAC control within a macro

Status
Not open for further replies.

kenaruj

Programmer
Jun 2, 2006
16
US
I am trying to create a macro within 53A that displays the OE1300 control and modifies the default values that appear.

I’ve added a reference to ‘Picking Slips (AccpacOE1300) ACCPAC UI Control’ and have placed the control on a new UserForm within the macro. I have been able to set the checkbox values and hide the buttons on the form with the following code:

Private Sub AccpacOE1300UICtrl1_OnUIAppOpened()
With Me.AccpacOE1300UICtrl1
.UIAppControls("APP_Print_Button").MacroVisibleFlag = False
.UIAppControls("APP_Close_Button").MacroVisibleFlag = False
.UIAppControls("cmdAlign").MacroVisibleFlag = False
.UIAppControls("chkPrintBOMItems").Value = 1
End With
End Sub

But cannot figure out how to change the value of the combobox or change the value of the report file that it uses. I would like to change the Select By combobox to ‘Order Number’ and the Sort By combobox to ‘Item Number’. I would also like to change the Use Slip to a specific report, but still allow the user to use the ‘Browse…’ button if need be.

Also- is there a way to add CommandButtons to the UserForm and have them appear on top of the ACCPAC control? Send To Back and Bring To Front do nothing nor does ZOrder. I can change the BackStyle of the Accpac control to transparent, but then the labels dissapear. Aagh!

Thanks
 
[UPDATE]

I've found a partial workaround for changing the values of the combo boxes. If I run the macro and change the Use Slip, Select By, and Sort By areas and then right click on the form to bring up the settings menu and click 'Save Settings As Defaults' then next time the macro is ran, those same settings are preserved (even after restarting ACCPAC).

I would rather be able to change them in code, but is it possible?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top