Hi Carsten,
Thank u...i had already searched in the code snippetbase but i cannot find
the solution. any way now i got a doubt in macros. I had created menus
programtically and i tried to link the menus to macros by the code
PropertyValue[] oMenuItem = CreateMenuItem(
"macro:///WebWizard.Language.LoadLanguage()", "HelloWorld");
where i created CreateMenuItem function as
public static PropertyValue[] CreateMenuItem(String command, String label) {
PropertyValue[] aMenuItem = new PropertyValue[] { new
PropertyValue(),
new PropertyValue(), new PropertyValue() };
aMenuItem[0].Name = "CommandURL";
aMenuItem[0].Value = command;
aMenuItem[1].Name = "Label";
aMenuItem[1].Value = label;
aMenuItem[2].Name = "Type";
aMenuItem[2].Value = new Integer(ItemType.DEFAULT);
return aMenuItem;
}
this code worked.............but if i change the code as
PropertyValue[] oMenuItem = CreateMenuItem(
"macro:///HelloWorld.HelloWorld.printHw", "HelloWorld");
it is not working.where "HelloWorld.HelloWorld.printHW" is java macro below
OpenOffice.org Macors and
"WebWizard.Language.LoadLanguage" is a macro under My Macro's (seen it in
tools->macros->runmacros). what to do now??how to access the java macros
inside OpenOffice.org Macros...