Question Patrik Spisak · May 24, 2025

Hi,

How do I create CSP page in IIS to be loaded from the class? 

Im able to open my index.html but I have class webapp.init.cls which extends %CSP.Page which should generate html. If I write localhost/myapp/webapp.init.cls I just got an error Invalid action.

In IIS Handler Mappings I did setup for *.cls and *.csp files. 

I followed this

https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cl…

When I created index.csp my IIS just return NOT FOUND. With the old APACHE server I had no issue with all, but Im trying to migrate to IIS.

1
0 108
Question Patrik Spisak · Apr 19, 2025

After upgrading from 2024 to 2025 Im not able to compile any class.

I was using ZPM and git-source-control.

Now Im getting 

 

Compilation started on 04/19/2025 20:53:00 with qualifiers 'cuk /checkuptodate=expandedonly'

ERROR #5002: ObjectScript error: <CLASS DOES NOT EXIST>OnAfterSave+4^SourceControl.Git.Extension.1 *SourceControl.Git.Utils
Detected 1 errors during compilation in 0.209s. class '%Studio.SourceControl.Interface', method 'OnBeforeTimestamp': <CLASS DOES NOT EXIST> 150 

I disabled SourceControl in Management portal and nothing happen.

2
0 156
Question Patrik Spisak · Nov 28, 2024

I have issue with one of my queries. That query work fine for ages, but suddenly stop works and giving me SQLCODE 100 in the routine. 

&SQL(
	  SELECT * FROM (
		SELECT event FROM dhr_log_lasers.production WHERE createDateUTC >= DATEADD(dd, -5, CURRENT_DATE) AND kiosk = :%var("kioskID") GROUP BY machine
		HAVING ID = MAX(ID)
	  ) WHERE event != 2
	 )

If I copy this same query to the management portal and replace variable with real ID I will get back 6 or more rows.

2
0 192
Question Patrik Spisak · Nov 4, 2022

How do I create recursive classmethod which stop all methods from running when condition are meet?

ClassMethod workpieceUnit(mainArticle As %String, article As %String) As %String
{
	
	&SQL(SELECT unit->unitCode INTO :unitCode FROM production_article.composition WHERE mainArticle = :mainArticle AND article = :article)
	
	IF SQLCODE = 0
	{
		W !, "Has Value"
		QUIT unitCode
	}
	ELSE
	{
		SET sql = "SELECT article, unit->unitCode,  production_article.composition_sqlArticleCode(article, type) AS articleCode FROM production_article.
6
0 604
Question Patrik Spisak · Dec 2, 2020

Hi guys,

I have this method to create object from XML

ClassMethod XMLNew(doc As %XML.Document, node As %Integer, contOref As %RegisteredObject = "") As TruLaser.ProductionPackage
{
    Set id=""     Set tmpnode=doc.GetNode(node)
    Do tmpnode.MoveToFirstChild()
    Do {
        //compare data node to the string given by the NAMEOFEXPORTID parameter
        //which indicates the XMLNAME of the ids for this object
        If tmpnode.NodeData=..#NAMEOFEXPORTID {
            //get the text from this node; this corresponds to an id in the database
            Do tmpnode.GetText(.id)}
        While tmpnode

1
0 428
Question Patrik Spisak · Apr 7, 2020

Hi guys,

I have read thos two links how to translate CSP application 

 

https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=GCSP_localization_tags#GCSP_localization_tags_compile

https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=ASTRLOC#ASTRLOC_localization_util_export

 

I have exported strings to XML

 

1
0 258
Question Patrik Spisak · Apr 6, 2020

HI,

 

I have sample %session like this

 

%session.Data("product", "1") = "Product 1"

%session.Data("product", "2") = "Product 2"

%session.Data("product", "3") = "Product 3"

%session.Data("product", "4") = "Product 4"

%session.Data("product", "5") = "Product 5"

How can i loop in tag based CSP application over %session?

if i have <csp:while condtion="">  Is there something like %session.Data("products").Next() ?

1
0 273
Question Patrik Spisak · Feb 14, 2020

Hi guys,

I need help because I have no idea how to proceed further and documentation does not explaining this solution.

I have XML like this:

  <Barcode>1200002101</Barcode>

  <DueDate>31.12.5000 23:59:59</DueDate>

  <BasicMaterial>1.

9
0 915