EducationSoftwareStrategy.com
StrategyCommunity

Knowledge Base

Product

Community

Knowledge Base

TopicsBrowse ArticlesDeveloper Zone

Product

Download SoftwareProduct DocumentationSecurity Hub

Education

Tutorial VideosSolution GalleryEducation courses

Community

GuidelinesGrandmastersEvents
x_social-icon_white.svglinkedin_social-icon_white.svg
Strategy logoCommunity

© Strategy Inc. All Rights Reserved.

LegalTerms of UsePrivacy Policy
  1. Home
  2. Topics

KB484869: Programmatically created SendNow subscriptions do not appear in the Developer Configuration Manager Subscription view


Community Admin

• Strategy


This article describes an issue where subscriptions that are programmatically created using SendNow are not visible in the Developer Configuration Manager Subscriptions view. This article also includes information on how to alleviate and resolve this behavior.

Description

Subscriptions that are programmatically created using SendNow are not visible in the Developer Configuration Manager Subscriptions view. 

ka0PW0000000kndYAA_0EM4W000001Kn2M.jpeg

The purpose of this KB article is not to provide full steps on how to create a SendNow subscription programmatically, but to alleviate the behavior where subscriptions created programmatically are not displayed in the above view from Developer.

Why is this happening?

If the subscription that was created programmatically using Strategy's Java Web APIs does not appear in the Subscriptions view of Developer, it is most likely the result of not having an associated subscription trigger. Strategy Tutorial examples of valid subscription triggers can include “First of the Month”, “All of the Time”, etc.


/* This code creates the WebSubscriptionsSource object to generate the WebSubscription object with the value of “myNewWebSubscription”
/*
myNewWebSubscription.sendNow(true);
myNewWebSubscription.save();

Solution

Make a code adjustment to add the subscription trigger to your WebSubscription object prior to saving the subscription.

  • Navigate to Developer > Administration > Configuration Manager > Schedules.
  • Identify the Schedule (subscription trigger) you want to associate with the SendNow subscription. Right-click it and choose Properties.
ka0PW0000000kndYAA_0EM4W000001Kn35.jpeg
  • Copy the ID for the schedule.
ka0PW0000000kndYAA_0EM4W000001Kn3Z.jpeg
  • Modify the code snippet below with the ID you copied.
    
    /* This code creates the WebSubscriptionsSource object to generate the WebSubscription object with the value of “myNewWebSubscription”
    */
    myNewWebSubscription.sendNow(true);
    /* In the code below, wos.getObject(String, int); is a WebObjectSource. The latest set of documentation regarding this call can be found here:
    https://www2.Strategy.com/producthelp/Current/WebAPIReference/com/MicroStrategy/web/objects/WebObjectSource.html#getObject (java.lang.String,%20int)
    */ 
    String modifyMeWithYourScheduleID = “FF7BB3C811D501F0C00051916B98494F”
    WebSubscriptrionTrigger trigger = (WebSubscriptionTrigger) wos.getObject(modifyMeWithYourScheduleID,EnumDSSXMLObjectTypes.DssXmlTypeScheduleTrigger);
    trigger.populate();
    myNewWebSubscription.setTrigger(trigger);
    myNewWebSubscription.save();
    


Comment

0 comments

Details

Knowledge Article

Published:

February 3, 2021

Last Updated:

February 14, 2024