cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

GenerateWebSite() call in Java

Rakeshkonjengba
Contributor

Hi,

 

I am trying to autogenerate the website in java.

But when I call GenerateWebSite() method, it says "the method GenerateWebSite() is undefined for the type MegaObject".

Below the code snippet:

 

MegaObject oWebs = null;

cWebs = oMegaRoot.getCollection("Web Site");
sWebSite = properties.getProperty("WebSiteNm");
if (cWebs.size() > 0) {
// Get existing web site ojbet (we assume that is can be

oWebs = cWebs.get(sWebSite);


// trigger web site generation

System.out.println("Website Name..." + sWebSite);
System.out.println("Starting the website generation..."
+ date.toString());

 

oWebs.GenerateWebSite();

 

Please advice on this

 

2 Replies

thxs..:)

It worked

Hi,

 

To autogenerate website in java, you can do this:

 

MegaCollection cWebs = oMegaRoot.getCollection("Web Site");

MegaObject oWeb = cWebs.item("WebSiteNm");

oWeb.invokeMethod("GenerateWebsite");

 

 

<script id="F5_watermark"></script>