NetTalk Central

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - terryd

Pages: 1 2 [3] 4 5 ... 15
31
I have a website where customers access a browse with an inline select button. The icon is a tick. Most of the users understand that they must click on the button but others don't understand it and say that all the choices are already ticked and try to double click the browse with no result.
A possible solution I would like to try is to have the button there but blank with no tick.
Hopefully this will lead the user to think of clicking the blank button where they wouldn't click the button with a tick (or so my customer believes)
Anyway I tried various things
Text in the Button properties - a blank or space has no effect but typing in 'click' replaces the tick with the word, entering '_' leaves the tick and puts an underscore beneath it
Images in Button properties - blank or space has no effect. Haven't tried nominating a blank item 
Set image width and image height to 0 - no difference
In the CSS classes tab tried '' and ' ' in the select button set no difference

None of the above worked.
I would only like to do this on certain screens, not all selects, just those on browses open to the public.
Anyone with a quick fix?

32
Web Server - Ask For Help / Location of Filter String in a Browse
« on: November 02, 2015, 01:27:29 AM »
Using a Filter String
Hi Bruce referring to the Webinar82 last Thursday. at the 0.09 minute mark you were talking to Bijan about storing String filters into variable.
Was there a reason that you ignored  the Start of Browse Filter embed point and suggested that the variable be generated and inserted somewhere here before the first
  ThisView{prop:Filter} = loc:FilterWas
 code
---->
  TableQueue.Kind = Net:RowData
  if p_web.sqlsync then p_web.RequestData.WebServer._Wait().
  Open(ThisView)
  If Loc:LocateField = 'EPFSAUTHD:AMECB_CLAIM_STATUS_DATE' then Loc:NoBuffer = 1.
  If Loc:NoBuffer = 0
    Buffer(ThisView,10,0,0,0) ! causes sorting error in ODBC, when sorting by Decimal fields.
  End
  If Instring('epfsauthd:guid',lower(loc:vorder),1,1) = 0 !and EPFSAuthDirect{prop:SQLDriver} = 1
    loc:vorder = Choose(loc:vorder='','UPPER(EPFSAUTHD:GUID)',clip(loc:vorder) & ',' & 'UPPER(EPFSAUTHD:GUID)')
  End
  Loc:Selected = Choose(p_web.IfExistsValue('EPFSAUTHD:GUID'),p_web.GetValue('EPFSAUTHD:GUID'),p_web.GetSessionValue('EPFSAUTHD:GUID'))
  ThisView{prop:order} = p_web.CleanFilter(ThisView,clip(loc:vorder))
  ThisView{prop:Filter} = loc:FilterWas
  Loc:LocatorValue = p_web.GetLocatorValue(Loc:LocatorType,loc:divname,Net:Both,Loc:LocateOnFields)
  ! Start of "Browse Filter"
  ! [Priority 5000]

Whenever I have had to create a complex Filter I have used The Start of Browse Filter embed like this
FilterStrings  GROUP,PRE(FILT) ! ID:10cd7318-32e4-4a31-8ee7-af94f98857b5
PolicyNoFilter   STRING(255) ! ID:1c8f205e-2f83-43c6-a258-71f22b99e669
AccountNoFilter  STRING(255) ! ID:68efe260-0643-4854-8e6d-b6191eb65e82
ClaimNoFilter    STRING(255) ! ID:eac9f357-6be8-45f2-8045-714bf2efae18
SurnameFilter    STRING(255) ! ID:b244516c-17e8-48ec-a9a3-3a3a69b4d274
IMEIFilter       STRING(255) ! ID:3be55dda-dd36-4e24-8c5a-0c3d964a99ef
ContactFilter    STRING(255) ! ID:43fda989-5702-4e2d-a2c9-04784cdfc734
IDNOFilter       STRING(255) ! ID:d2afb19d-7d90-45f6-be08-1e29a2eb4171
               END
CLEAR(FilterStrings)
IF p_web.GSV('PolicyNo') <> ''
    FILT:PolicyNoFilter = 'EPFSAUTHD:AMECB_POLICY_NBR = <39>' & p_web.GSV('PolicyNo') & '<39>'
END
IF p_web.GSV('AccountNo') <> ''
    FILT:AccountNoFilter = 'EPFSAUTHD:AMECB_ACCT = <39>' & p_web.GSV('AccountNo') & '<39>'
END
IF p_web.GSV('ClaimNo') <> ''
    FILT:ClaimNoFilter = 'EPFSAUTHD:AMECB_CLAIM_NBR = <39>' & p_web.GSV('ClaimNo') & '<39>'
END
IF p_web.GSV('Surname') <> ''
    FILT:SurnameFilter = 'EPFSAUTHD:AMECE_N_SURNAME = <39>' & p_web.GSV('Surname') & '<39>'
END
IF p_web.GSV('ClaimIDNo') <> ''
    FILT:IDNOFilter = 'EPFSAUTHD:IDNo = <39>' & p_web.GSV('ClaimIDNo') & '<39>'
END
IF p_web.GSV('IMEI') <> ''
    FILT:IMEIFilter = 'EPFSAUTHD:AMECE_CP_IMEI_NBR = <39>' & p_web.GSV('IMEI') & '<39>'
END
IF p_web.GSV('CustomerContactNumber') <> ''
    FILT:ContactFilter = 'EPFSAUTHD:CustomerContactNumber = <39>' & p_web.GSV('CustomerContactNumber') & '<39>'
END
loc:FilterWas = CLIP(FILT:PolicyNoFilter)
IF FILT:AccountNoFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:AccountNoFilter)
    ELSE
        loc:FilterWas = CLIP(FILT:AccountNoFilter)
    END
END
IF FILT:ClaimNoFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0    
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:ClaimNoFilter)
    ELSE
        loc:FilterWas = CLIP(FILT:ClaimNoFilter)
    END
    
END
IF FILT:SurnameFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0        
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:SurnameFilter)
    ELSE
        loc:FilterWas = CLIP(FILT:SurnameFilter)
    END
        
END
IF FILT:IDNOFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0        
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:IDNOFilter)
    ELSE
        loc:FilterWas = CLIP(FILT:IDNOFilter)
    END
        
END
IF FILT:IMEIFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:IMEIFilter)
    ELSE
        loc:FilterWas =  CLIP(FILT:IMEIFilter)            
    END
            
END
IF FILT:ContactFilter <> ''
    IF LEN(CLIP(loc:FilterWas)) <> 0
        loc:FilterWas = CLIP(loc:FilterWas) & ' AND ' & CLIP(FILT:ContactFilter)
    ELSE
        loc:FilterWas = CLIP(FILT:ContactFilter)                
    END
                
END
IF LEN(CLIP(loc:FilterWas)) = 0
    loc:FilterWas = 'EPFSAUTHD:AMECB_ACCT = <39>xx<39>'
END


ThisView{prop:Filter} = loc:FilterWas  

Is there a reason that this is incorrect?

33
Web Server - Ask For Help / Web browser not connecting to webserver
« on: October 14, 2015, 01:36:29 AM »
I have one web application where a webbrowser can't connect to the webserver.
I have checked that the port and app is allowed through the windows Firewall (the allow connection screen came up)
I checked via netstat -ano that no other application is listening on the port
The webapp starts and I can see the port it is listening on in netstat
In the webbrowser i enter http://127.0.0.1:8088
I get a blank screen with the message connecting and the busy indicator.
Nothing shows on the log page
This can go on for a long time.
If I stop the webapplication I immediately get a message Problem loading page on the browser and that the connection was reset so the browser was definitely trying to  connect to the right port.
I have also placed a trace in theWebhandler Process Link procedure just to see if it was accessed but nothing appears.
Are there any other embed points that I can enter traces it to see where, or why I can't connect?

34
Is is possible to suppress the pageheader or the menu or the footer when calling specific pages?
Assume I have a website http://test.com.
I have a NetwebForm called registration
If I have a menu choice for registration and click it I get http://test.com/registration. When the form displays
There is a PageHeader
There is the Menu displaying unhidden menu choices (home,Registration,Login)
There are the registration form fields
There is a Page footer

IF I give the potential user a direct link to http://test.com/registration I would like to hide one or more of PageHeader, Menu PageFooter, specially the Menu while displaying the Registration page since this distracts from what I want the user to do (fill in and accept the form).
Is there a way to temporarily do that and then restore the Menu/PageHeader etc after save?
Currently I have created another webserver with no menu http://test:81/registration which does what I want but I would prefer to have one application doing all.

35
Web Server - Ask For Help / Creating a XSD file
« on: October 07, 2015, 08:04:26 PM »
I need to generate a XSD file from a spec supplied by a customer.
It looks like standard XML.
Can they be created with xfiles?
If so has anyone worked with creating them using Xfiles?

36
Hi I have this code in Nettalk and it works, it opens the page as I expect:
p_web.Script(  P_web.WindowOpen('http://www.albertonday.co.za/albertonday-stalls_6.html') )
What I now  need to do is call a site that sends an SMS message to a nominated cell number.
The site requires parameters.An example of the line that I can enter directly into the URL is

https://www.winsms.co.za/api/batchmessage.asp?User=testuser&Password=stefan&Message=You can register&Numbers=27824410959

If I run this this the remote site completes the operation and returns a success or fail message

How can I integrate this into my webapp so that it completes the operation. I am not really interested in the result in this case since the fail would indicate that the user had entered a ficticious cell number and thus would be denied entry to the system.

I had thought to use the p_web.Script routine like this:
p_web.Script(  P_web.WindowOpen('https://www.winsms.co.za/api/batchmessage.asp?User=testuser&Password=stefan&Message=You can register&Numbers=27824410959') )
but it opens the site and the line is changed to:
https://www.winsms.co.za/api/batchmessage.asp?User=testuser&amp;Password=stefan&amp;Message=You%20can%20register&amp;Numbers=27824410959
which doesn't happen with the straight URL entry and an error message Error="No message given" is returned

What I would like to achieve is to just call the url and continue with no result reported back.
Any advice appreciated


37
Web Server - Ask For Help / Problem using ServerWebServiceWizard
« on: September 10, 2015, 08:51:23 AM »
Hi Trying to use the Server WebService Wizard to create a webservice. See the attached 5 images. This happens every time I follow this procedure. Is there something else I should do I have only seen examples of webservices being setup using the new application Nettalk wizard so maybe there is something else I should do.

[attachment deleted by admin]

38
I have a netwebPage called CheckAvailability on my webserver
A client has a website on which he has various hotspots.
Clicking a hotspot links him to a url www.mysite\CheckAvailability?stall=F01


If I don't find a matching record I redirect the user to the calling website.
   p_web.Script(  P_web.WindowOpen('http://www.callingsite.co.za.html') )

If I find a matching record with this value I pass the user through to my website index page where he can register and then login.
        p_web.Script('ntAlert("This Stall is still available.","Wonderful");')   
        p_web.Script(  P_web.WindowOpen('IndexPage') )

The internal logic works fine.
My problem
   This line only displays for a fraction of a second
   p_web.Script('ntAlert("This Stall is still available.","Wonderful");')   
I understand from what Kevin (MyBrainIsFull) said that it needed a page for the alert message to stay on the screen.
   What I would like to do then is when the menu displays if the sessionvariable that the stall number is stored in is not blank to display an alert message.
Something in the nature of:
If you have not visited the website before please register otherwise login with your assigned password.
which I would like to stay on the screen until the user clicks OK.
Where should I place this code to achieve this effect?

39
In standard Clarion applications related parent and Grandparent tables would be setup in the Schematic. I don't need to do any lookups since they are handled by this relationship setup and I can display the original values on the screen
In a Nettalk Form they aren't.
I have a Table which has certain fields related to other parent tables and those parent tables have in their turn related parent tables.
If I want to just display some of the parent/grandparent values in my form what I currently do is create a set of local values and in the PreUpdate embed point I open the various parent tables and read the values and store them to the local variables and then display those variables.

Is this the best way to do this?

40
I know I have seen a thread on this subject but I cannot find it.
I have a ParentBrowse
One of the fields displayed on the browse is a status
The Browse has a ChildBrowse which displays filtered records based on a linking field.
If I change a record in the the ChildForm I do some checking and if certain criteria are met I open the ParentFile in postUpdate and change the status.
All this works as expected, the status displayed in the ChildBrowse after returning is correct (I have checked "Refresh whole browse after change"), but the ParentBrowse is not refreshed.
Re-selecting the menu choice refreshes the ParentBrowse which then displays the correct information
How do I refresh the ParentBrowse after changes made in the ChildForm?
 

41
Web Server - Ask For Help / Advice Display changing Background Images
« on: September 01, 2015, 01:08:00 AM »
In one of my apps in the IndexPage XHTML I have a routine with the XHTML in capture1.jpg
The contents of BodyContent.txt are very simple. It displays a background image when I'm logged out or when the user is logged in but a procedure isn't open.
What I would like to do is to have (let's say) 10 images in a folder
I can store the location and names in a sequentially numbered table.
Every time a new session is started I would like to access the name of the next image in the table and display that image as the background, at the same time marking the record as the last image accessed. When the next user logs in I could check the table access the next record, display the image as background, hopefully ad infinitum. At the end of the table go back to no 1
My question:
Is it possible to do this within the XHTML or am I looking at javascript?
At the moment this is just an experiment to see how far I can go but it would definitely be a plus in one of my mobile apps.
Any suggestions, pointers etc. would be appreciated.

[attachment deleted by admin]

42
Web Server - Ask For Help / Set Focus back to Invalid entry field
« on: August 31, 2015, 12:03:48 AM »
In a website I have a field that after entry is validated checking for length, numeric only etc.
If the validation passes I want it to go to the next field. Although it wasn't necessary I put the equate of the next field into the When accepted, Set Focus field.
The validation works. If it finds an error the Entry field clears, an alert message pops up but the focus jumps to the next field.
Is there a way to set focus back to the entry field if certain criteria fail in the validation routine.
This happens when Save is clicked so I am hoping to be able to hijack the method.
This is not such a problem in normal web mode since the alert pops up but in mobile the alert message doesn't show and it moves to the next field so probably the first time that the user realises that the field wasn't accepted is when he clicks save.

43
I have a netweb page which is a landing site from another client's website. I receive the parameter like this:
http://www.mysite.com/checkavailability/stall=F01 I have stored the value in the sessionvalue RequestedStall
I check in my database and can get 3 results
1.The stall with that number does not exist
2.The stall exists but has already been allocated to another applicant
3.The stall exists and can still be booked.

In the case of 1 and 2 I want to redirect back to the original website e.g. http:/www.show.com/map.htm
In the case of 3 I want to then send them to my website http://www.mysite.com/index where they will either login or register depending on whether they have accessed the site before.
I should have the SessionValue RequestedStall stored so when they go to the booking screen I can populate it with the relevant details
All the above logic works I can popup an alert message with the correct status but now I want to send them to the correct destination

My question is how do I code the redirect command within the NetWeb page?
Obviously <a href="http://www.mysite.com" >
or <a href="http:/www.show.com/map.htm" >
I also tried:
    packet.Append('<a href="http://www.mysite.com"> ')
    DO SendPacket
Where nothing happened
don't work so what do I do?

44
I have a client who has his own website.
On the website he has a map of a show terrain.
Each of the locations has a hot spot with a value (say 'S01') which when pressed can redirect to a URL.

Our idea is for him to redirect to my website with something like http://mywebsite.com/checkstatus/?S01.

What I want to do from my website is:
a. Check that that location is available. I have a table with an Unique identifier (not the Primary Key) which would be able to check the status of the record if I do something like
STA:Code = 'S01'
Access:Stall.Fetch(SK_StallCode)
One of the fields in the Stall table contains the status of the stall (Available/Not Available)
So I would then return a not available message or allow the user to continue is the status is available.

My question is if I received the above URL what would I need to do to store the value S01 into a session variable since once I have that the rest should be straightforward.

45
Web Server - Ask For Help / Application holding 2 ports
« on: August 15, 2015, 01:08:03 AM »
From Nettalk 4 days I have controlled the port I am using for my application via a table which allows me to have the same application using different ports without having to change the Listen On Port number in The Nettalk object and then having to recompile for different users.
I do it my placing this code in the WindowManager Init after Open Files
WEBCTL:WebControlID = 'aaaaaaaaaaaaaaaa'
IF ACCESS:WebControl.FETCH(WEBCTL:KEY_WebControlID)
    WebControlFound = FALSE
ELSE
    WebControlFound = TRUE
    CompanyName = CLIP(WEBCTL:CompanyName)
    HomeWebSiteAddress = CLIP(WEBCTL:HomeWebSiteAddress)
    IF HomeWebSiteAddress = ''
        HomeWebSiteAddress = 'web'
    END
    HTTPPort = WEBCTL:HTTPPort
    IF HTTPPort = 0
        HTTPPort = 80
    END
END
TaskbarDescription='[' & HTTPPort & '] ' & CLIP(CompanyName) & ' Location: ' & CLIP(HomeWebSiteAddress)
ACCESS:WebControl.Close()
ACCESS:WebLogin.Close()

For my development I normally use 8088 so that it doesn't clash with the 88 used by Capesoft in their examples although in the default settings in the Nettalk object I do have 88.

Previously I have never had an issue with this; the port is set to the port I specify in the code.
Lately ( going back quite a few versions of Nettalk8) I have noticed that Port88 was being blocked.
Only recently did I realise that this happened when I was running my app on 8088. I could access my application on 8088 as normal but I couldn't run a capesoft app on 88 at the same time.
I used netstat -ano in cmd I found that both port 88 and port 8088 were being listened to by the same pid, my exe.
Has there been a change that I didn't see that can cause this, and if so how should I change my app to allow me to continue without holding the default port.
Even though the app is supposedly listening on port88 I can't access it on that port.

Pages: 1 2 [3] 4 5 ... 15