Quantcast
Channel: SCN : Discussion List - PowerBuilder Developer Center
Viewing all articles
Browse latest Browse all 2881

Errors in WebDatawindow

$
0
0

Hi ,

I'm using Powerbuilder 11.5.1 built 5097

I have created a webservice where I'm returning the Html syntax of a datawindow. I'm taking this Html syntax, which Powerbuilder generates and displays it in my web site.

Inside the powerbuilder web service I have the below

lds_data.Modify("Datawindow.HTMLGen.HTMLVersion='4.0'")

          //assign the external javascript

          lds_data.Modify &

    ("DataWindow.HTMLGen.CommonJSFile='" + ls_javascript  + "'")  

 

and then I'm taking the Html Syntax with the below command

lds_data.Describe( 'DataWindow.Data.HTML' )

 

So far everything is working fine.

 

I am able to BIND my datawindow with the external javascript (I have generated the file using from the datawindow wizard) and I am able to GET the Html syntax. And also the events are being triggered. BUT.....

I have noticed in the Powerbuilder's Html Syntax the below javascript code which I think is not correct , because I'm getting some Javascript errors during the debbug.

For example

 

The html syntax is not structured correctly. Everything is in one row without carriage returns. This is a problem for the generated javascript because a line like the below (which is in one row)

// Get encoded format against mask var format = new DW_StringEncodingClass(Mask); // if invald mask, return false if (!format.bValid) return false; // Create a new number class var

 

It should be structured  as follows

 

// Get encoded format against mask

var format = new DW_StringEncodingClass(Mask);

// if invald mask, return false if (!format.bValid) return false;

// Create a new number class

var

etc etc etc

 

practically that means that the comment line , COMMENTS the rest of the javascript code and that results to javascript errors.

 

Is there any way to overcome this ????

 

Is there any way to format  , structure correctly the Html Syntax that the datawindo generates ?

Am I missing somthing ??

 

Appreciate any help you could give me.

 

thank you


Viewing all articles
Browse latest Browse all 2881

Trending Articles