Search found 710 matches

by swhite
Sat Mar 09, 2024 7:19 pm
Forum: Bugs - IDE
Topic: Is this a Line Continuation Bug?
Replies: 3
Views: 215

Re: Is this a Line Continuation Bug?

The first Bool() identifies matching brackets. The second version has problems. Bool(""=taRcvd(#KA_EMAIL) And Not SQLSeek(KHSite("pid")\ValueS+Left(lcCard,10),"KHCard","PID",KHCard()) And Not SQLSeek(KHSite("pid")\ValueS+Left(lcCard,9),"KHCard&q...
by swhite
Fri Mar 08, 2024 5:56 pm
Forum: Bugs - IDE
Topic: Is this a Line Continuation Bug?
Replies: 3
Views: 215

Is this a Line Continuation Bug?

Hi

The following line does not match the brackets correctly when the split over multiple lines. It works fine if the code is all on one line. I am using PB6.03 64bit

https://www.dciphercomputing.com/update ... ntinue.png

Simon
by swhite
Fri Mar 01, 2024 9:42 pm
Forum: Feature Requests and Wishlists
Topic: DatabaseQuery() could close previous query.
Replies: 2
Views: 238

Re: DatabaseQuery() could close previous query.

Thank-you that is very useful information to know. Can this be added to the documentation for the DatabaseQuery() function?

Simon
by swhite
Fri Mar 01, 2024 3:44 pm
Forum: Feature Requests and Wishlists
Topic: DatabaseQuery() could close previous query.
Replies: 2
Views: 238

DatabaseQuery() could close previous query.

Hi I would like to suggest that the DatabaseQuery() function automatically does a FinishDatabaseQuery() before executing the new query. This would make database programming safer in that the programmer would only have to be responsible to execute FinishDatabaseQuery() on the last query for any conne...
by swhite
Thu Feb 29, 2024 9:34 pm
Forum: Coding Questions
Topic: Does DatabaseQuery Release Previous Query's Resources?
Replies: 3
Views: 297

Re: Does DatabaseQuery Release Previous Query's Resources?

Hi

I was assuming that I would need to use the FinishDatabaseQuery() but was not absolutely sure. So thank-you for the clarification.

Simon
by swhite
Thu Feb 29, 2024 5:44 pm
Forum: Coding Questions
Topic: Does DatabaseQuery Release Previous Query's Resources?
Replies: 3
Views: 297

Does DatabaseQuery Release Previous Query's Resources?

Hi The documentation mentions that FinishDatabaseQuery() must be called to free the query resources. However, what happens in the following case with multiple queries? DatabaseQuery(2,"select * from mytable1") ... process the data DatabaseQuery(2,"select * from mytable2") ... pro...
by swhite
Sun Feb 25, 2024 3:56 am
Forum: Bugs - Documentation
Topic: Add an Example of Returning A String from a DLL
Replies: 5
Views: 362

Re: Add an Example of Returning A String from a DLL

Hi After more experimenting I discovered that you can return a string or a pointer to a memory buffer. If I return a string I still must treat the return value as a pointer and convert the string from Unicode to UTF8 in Visual Foxpro. If I use the a memory buffer I do not have to convert the result ...
by swhite
Sat Feb 24, 2024 7:46 pm
Forum: Bugs - Documentation
Topic: Add an Example of Returning A String from a DLL
Replies: 5
Views: 362

Re: Add an Example of Returning A String from a DLL

Hi I read the documentation before posting this suggestion. You cannot just return a string as shown in the example below. You have to return the pointer to the string. Global ReturnString$ ProcedureDLL.s MyFunction(var.s) ReturnString$ = var + " test" ProcedureReturn ReturnString$ EndProc...
by swhite
Fri Feb 23, 2024 3:56 pm
Forum: Bugs - Documentation
Topic: Add an Example of Returning A String from a DLL
Replies: 5
Views: 362

Add an Example of Returning A String from a DLL

Hi I read through the documentation about creating a DLL and the only condition it mentioned was that the string must be declared as Global but it does not mention that the return value is a pointer to the string. So It would be very helpful if there was an example of returning a string from a DLL. ...
by swhite
Fri Feb 23, 2024 3:52 pm
Forum: Coding Questions
Topic: How to Return a String from Windows DLL
Replies: 5
Views: 250

Re: How to Return a String from Windows DLL

I did not realize the return value was a pointer to the string. Now I have it working correctly so thank-you to everyone.

Simon
by swhite
Thu Feb 22, 2024 8:26 pm
Forum: Coding Questions
Topic: How to Return a String from Windows DLL
Replies: 5
Views: 250

How to Return a String from Windows DLL

Hi When I call the Encrypt function from this PB dll from another Windows application all I receive is the "C" but I should be receiving the entire encrypted string. Can someone tell me what I have done wrong? ; ; AES Encryption key and Initialization Vector ; DataSection Key: Data.b $25, ...
by swhite
Mon Feb 19, 2024 5:34 pm
Forum: Tricks 'n' Tips
Topic: WebUI wrapper
Replies: 43
Views: 6508

Re: WebUI wrapper

Thank-you for pointing that out. It does work once I add the webui.js script.

Simon
by swhite
Mon Feb 12, 2024 3:39 pm
Forum: General Discussion
Topic: [Done] Postgres Column Types
Replies: 4
Views: 390

Re: Postgres Column Types

Thank-you.

Fred wrote: Sun Feb 11, 2024 9:58 amFixed.
by swhite
Mon Feb 12, 2024 3:37 pm
Forum: General Discussion
Topic: [Done] Postgres Column Types
Replies: 4
Views: 390

Re: Postgres Column Types

Yes I understand I can do this but it makes it difficult to handle database tables in a generic way. I would have to test whether the field contained a decimal point which slows down the loading of data. Thankfully Fred says this is fixed. If you look into the packets with wireshark, you can see tha...
by swhite
Fri Feb 09, 2024 10:23 pm
Forum: General Discussion
Topic: [Done] Postgres Column Types
Replies: 4
Views: 390

[Done] Postgres Column Types

Hi I am accessing a Postgres database that has fields defined as numeric(10,3) or numeric(6,4) etc. However, PB returns the column type as 1 (Long). I was expecting double so I do not lose the decimal point. Is this a bug? I am using PB 6.03 (x64) with Postgres 14. I was expecting a mapping similar ...