Jump to content

All Activity

This stream auto-updates     

  1. Today
  2. jorn

    License (Gumroad)

    As Jarto says: We agree with you on your Gumroad-thoughts. That's why we have moved away from Gumroad, and started using Stripe instead. The license _was_ sent to the registrered email when the subscription was automatically renewed. Some months ago. Did you try to re-request the license from Gumroad or something? If so, then I suppose that we don't get any notification of this on our side.
  3. bestm80eva

    RoadMap 2019

    I am looking to purchase SMS but find the documentation lacking and no roadmap. Please help
  4. Dany

    License (Gumroad)

    Thanks!
  5. Yesterday
  6. jarto

    License (Gumroad)

    Hi, Gumroad's automatic license mailing has not been working for a long time. That's why we've moved all new purchases to Stripe. I'll ask Jörn to send the license to you asap. Sorry about the delay and the trouble. @jorn
  7. Dany

    License (Gumroad)

    I'm pretty sure i'm getting billed via "Gumroad"*. No i'm sure. Yesterday i downloaded the latest version but my license is not up to date. I went into gumroad and received an e-mail stating that "We will send you the license key shortly.". What is shortly? I'd like to test some aspects of the latest SMS, please! Kind regards, /D * I must say this must be one of the most frustrating "sites" from the viewpoint of a subscriber. I'd guess a lot of designers and "visionaries" are involved
  8. jarto

    Statistics

    Having a look at this now. This is pretty simple to handle by using TApplication.OnActivate and OnDeactivate. There's some more work to do also: Designing Time ticks all the time if the form designer is visible. It should react to changes just like Editing Time does. Build duration is not updated. The Statistics form could use a Clear-button.
  9. Last week
  10. jarto

    Renaming form in ObjectInspector

    Thank you for your comments. @IgorSavkic's suggestion makes perfect sense. To sum this up: Rename from Project Manager: Change unit name Change file name NO changes to form class name Rename from Property Inspector: Change form class name NO changes to unit name NO changes to file name
  11. lynkfs

    Renaming form in ObjectInspector

    Looking at @IgorSavkic's argument to be able to have different form class names and unit names, I agree with him. We all have different styles and the IDE should accommodate that (so only the project manager should change unit/file names)
  12. IgorSavkic

    Renaming form in ObjectInspector

    > Through Project manager: Through Property Inspector I think SMS in this should behave as Delphi. Project manager operates on units, so it will display unit name (for example MainForm.pas) and renaming there, renames unit. Object/Property inspector operates on components, so changing form name just does that, changes form name and class, unit is unaffected. For forms units I do like to have a different unit name and a different form name, for example I prefix all controls with it's type abbreviation, something like: Unit: SettingsForm.pas FormControl: frmSettings Panel: pnlMain ListBox: lbItems Panel: pnlRight ListBox: lbCategories Panel: pnlBottom Button: btnOK Button: btnCancel
  13. lynkfs

    Renaming form in ObjectInspector

    This behaviour is not limited to Forms but to other classes as well For example: Looking at the 'unit structure' tab with the SmartCL.Borders unit open, I can rename the TW3Border class to something else For Forms I don't see any advantage of changing a form class and not change the unit and filename, but for other object classes changing the class name only is somewhat handy (although a search and replace old/new classname will have the same effect)
  14. jarto

    Renaming form in ObjectInspector

    I'm starting to get an idea of where the problem is. But before I can fix this, I'd like to ask you guys for your opinion on what the expected behavior should be. Because currently the renaming happens differently in the Property Inspector and Project Manager: Through Project manager: Form class is changed Unit name is changed File name is changed Through Property Inspector: Form class is changed Unit name is NOT changed File name is NOT changed Should I make both behave the same way or do you guys see an advantage in these behaving differently? Please let me know.
  15. jarto

    Renaming form in ObjectInspector

    Ahh, now I get it. You're renaming from the Property Inspector and not from the Project Manager. I can reproduce this reliably now. Next step is to fix it.
  16. lynkfs

    Send an email ?

    yep (works @ my place)
  17. IElite

    Send an email ?

    Oh ok, so if I upload the project to my server, then it should work?
  18. lynkfs

    Send an email ?

    This api doesn't allow local execution (file:///C:/Users/.../www/index.html) but requires a http(s) based url (https://.../www/index.html) so index.html / index.js needs to be server-side
  19. IElite

    Send an email ?

    Not sure I follow you. So the code is not for Browser?
  20. Erik zimmerman

    My SMS Project: Paintball Net Revival

    David... I would love to get access into E Z. Also lvl 90 Been a long long time. Very happy your playing with old habits again. Erik
  21. lynkfs

    Send an email ?

    I checked, runs perfectly well server-side (but not client-side)
  22. lynkfs

    Quantum computing with Smart

    Is it possible to do a bit of quantum computing using SMS ? The answer looks to be yes, using IBM's quantum computer resources which are partly made available for developers Basics first : IBM has released it's SDK to program these quantum computers using a visual composer, Python, a proprietary assembler QASM format and some run and execute utilities. There is however a second way of using its quantum resources, using the entry-points of is Q-experience REST server. Most if not all of the visual composer functions can be done by ajax-calls ! To demonstrate : the first thing is to acquire an api-token. (Create an account on https://quantumexperience.ng.bluemix.net/qx/experience. Log in and navigate to the Composer. Username > My Account, and then Advanced on the upper right. Then generate API Token. Api Tokens are personal and are not supposed to be shared.) The next thing is to generate a session token (access token). This can be done in code. This screenshot shows a couple of these REST server calls and its results : The first button (get access) generates a session token The second button queries which quantum computers are available, how many qubits can be used, if it is online and what type of system it is. Current results show 3 quantum systems - 2 real ones and 1 simulator The third button (current Temp) gives some processor info of the selected system. In this case the current temperature in Kelvin : the Melbourne processor is cooled to just above the absolute minimum. Next : the next button to implement will be to submit some code to one of the available processors for processing. Below is the project code for these REST calls unit Form1; interface uses System.Types, System.Types.Convert, System.Objects, System.Time, SmartCL.System, SmartCL.Time, SmartCL.Graphics, SmartCL.Components, SmartCL.FileUtils, SmartCL.Forms, SmartCL.Fonts, SmartCL.Theme, SmartCL.Borders, SmartCL.Application, SmartCL.Net.Http, ECMA.Json, SmartCL.Controls.Button, SmartCL.Controls.Label, HTMLTableElement, SmartCL.Controls.ScrollBox, SmartCL.Controls.Panel, SmartCL.Controls.ComboBox; type TForm1 = class(TW3Form) procedure W3Button3Click(Sender: TObject); procedure W3Button2Click(Sender: TObject); procedure W3Button1Click(Sender: TObject); private {$I 'Form1:intf'} protected procedure InitializeForm; override; procedure InitializeObject; override; procedure Resize; override; DBRows : integer := 0; FHttp : TW3HttpRequest; smscursor: variant; procedure GetAccessToken(Sender: TW3HttpRequest); procedure ListAvailableSystems(Sender: TW3HttpRequest); procedure GetTempKelvin(Sender: TW3HttpRequest); AccessToken : string; end; implementation { TForm1 } procedure TForm1.InitializeForm; begin inherited; // this is a good place to initialize components end; procedure TForm1.InitializeObject; begin inherited; {$I 'Form1:impl'} end; { Button1 } procedure TForm1.W3Button1Click(Sender: TObject); begin //Get Access Token var FHttp := TW3HttpRequest.Create; FHttp.OnDataReady := GetAccessToken; FHttp.open("POST",'https://quantumexperience.ng.bluemix.net/api/users/loginWithToken'); FHttp.RequestHeaders.Add("Content-type","application/json"); var api : variant := new JObject; api.apiToken := TString.encodeURIComponent('a59d26ebf........1d6d6d4a28c430b5336aba'); FHttp.send(json.stringify(api)); end; procedure TForm1.GetAccessToken(Sender: TW3HttpRequest); begin smscursor := JSON.parse(Sender.ResponseText); AccessToken := smscursor.id; W3Label1.Caption:= 'Access Token : ' + AccessToken; end; { Button2 } procedure TForm1.W3Button2Click(Sender: TObject); begin //List available Q systems var FHttp := TW3HttpRequest.Create; FHttp.OnDataReady := ListAvailableSystems; FHttp.open("GET",'https://quantumexperience.ng.bluemix.net/api/Backends?access_token=' + AccessToken); FHttp.RequestHeaders.Add("Content-type","application/json"); FHttp.send; end; procedure TForm1.ListAvailableSystems(Sender: TW3HttpRequest); begin var W3TableElement1 : TW3TableElement := TW3TableElement.Create(W3Panel1); //add 5 columns to the grid W3TableElement1.AddColumn('Name',200); //title, width W3TableElement1.AddColumn('Description',200); W3TableElement1.AddColumn('Qubits',50); W3TableElement1.AddColumn('System type',150); W3TableElement1.AddColumn('Status',50); smscursor := JSON.parse(Sender.ResponseText); W3ComboBox1.Clear; for var i := 0 to smscursor.length -1 do begin W3TableElement1.AddCell(i+1,1,smscursor[i].name); W3TableElement1.AddCell(i+1,2,smscursor[i].description); W3TableElement1.AddCell(i+1,3,smscursor[i].nQubits); if smscursor[i].simulator = true then W3TableElement1.AddCell(i+1,4,'quantum simulator') else W3TableElement1.AddCell(i+1,4,'quantum system'); W3TableElement1.AddCell(i+1,5,smscursor[i].status); W3ComboBox1.add(smscursor[i].name); end; W3Panel1.NativeScrolling := true; W3ComboBox1.OnChanged := procedure (Sender: TObject) begin writeln(W3ComboBox1.Items[W3ComboBox1.SelectedIndex]); end; end; { Button3 } procedure TForm1.W3Button3Click(Sender: TObject); begin //Get Temp var FHttp := TW3HttpRequest.Create; FHttp.OnDataReady := GetTempKelvin; //'https://quantumexperience.ng.bluemix.net/api/Backends/NAME/parameters?access_token=ACCESS-TOKEN'; FHttp.open("GET",'https://quantumexperience.ng.bluemix.net/api/Backends/' + W3ComboBox1.Items[W3ComboBox1.SelectedIndex] + '/parameters?access_token=' + AccessToken); FHttp.RequestHeaders.Add("Content-type","application/json"); FHttp.send; end; procedure TForm1.GetTempKelvin(Sender: TW3HttpRequest); begin If Sender.ResponseText = '{}' then begin W3Label3.Caption := 'Simulators are not cooled to (close to) absolute minimum'; end else begin smscursor := JSON.parse(Sender.ResponseText); if smscursor.fridgeParameters.Temperature.value = '' then W3Label3.Caption := 'Processor does not support Temp reading' else W3Label3.Caption:= 'Current Temp : ' + smscursor.fridgeParameters.Temperature.value + ' Kelvin'; end; end; procedure TForm1.Resize; begin inherited; end; initialization Forms.RegisterForm({$I %FILE%}, TForm1); end. In the end hopefully it will be possible to recreate the classic Battleships game using quantum computing, as described here
  23. IElite

    Send an email ?

    Sorry, I guess that was the wrong terminology to use. I haven't yet actually tried to send an email. All i have done was to add the all the code you provided above, particularly the smart enabled code. When I run my app , without sending the email, I get that error. I can't delete the scope line because it will complain - as I stated above. Not sure I can also delete the clientId ? Do you think?
  24. lynkfs

    Send an email ?

    if it runs fine by deleting part of code, by all means it may be that Google has tweaked the gmail api (client or auth2 library) slightly in the last couple of months
  25. lynkfs

    table grid

    the simplest of grids, based on the html <table> element usage var W3TableElement1 : TW3TableElement := TW3TableElement.Create(W3Panel1); //add 4 columns to the grid W3TableElement1.AddColumn('Name',200); //title, width W3TableElement1.AddColumn('Description',200); W3TableElement1.AddColumn('Type',150); W3TableElement1.AddColumn('Status',50); for var i := 0 to 2 do begin W3TableElement1.AddCell(i+1,1,'Name-'+inttostr(i)); //row,column,text W3TableElement1.AddCell(i+1,2,'Desc-'+inttostr(i)); W3TableElement1.AddCell(i+1,3,'Type-'+inttostr(i)); W3TableElement1.AddCell(i+1,4,'Stat-'+inttostr(i)); end; W3Panel1.NativeScrolling := true; component unit HTMLTableElement; interface uses SmartCL.System, System.Types, SmartCL.Components; type TW3TableElement = class(TW3CustomControl) protected function MakeElementTagObj : THandle; override; TableRow : Variant; public procedure AddColumn(title: string; colwidth: integer); procedure AddCell(row, column: integer; cell: String); ColumnCount : integer := 0; RowCount : integer := 0; end; implementation { TW3TableElement } function TW3TableElement.MakeElementTagObj : THandle; begin Result := w3_createHtmlElement('table'); end; procedure TW3TableElement.AddColumn(title: string; colwidth: integer); begin // Inc(ColumnCount); //when inserting the first column, do a rowInsert for the column titles If ColumnCount = 1 then begin TableRow := handle.insertRow(0); Inc(RowCount); end; // Insert a cell in the row at index [column] var newCell = TableRow.insertCell(columnCount-1); newCell.setAttribute('bgColor','lightgrey'); newCell.setAttribute('width',inttostr(colwidth)+'px'); // Append a text node to the cell var newText = browserapi.document.createTextNode(title); newCell.appendChild(newText); end; procedure TW3TableElement.AddCell(row, column: integer; cell: String); begin // //when inserting the first cell in a row, do a rowInsert If Column = 1 then begin TableRow := handle.insertRow(RowCount); Inc(RowCount); end; // Insert a cell in the row at index [column] var newCell = TableRow.insertCell(column-1); // Append a text node to the cell var newText = browserapi.document.createTextNode(cell); newCell.appendChild(newText); end; end. note : this is an upgraded unit as referred to in this post - method 1
  26. IElite

    Send an email ?

    @lynkfs I am trying your "smart" example out above However, it is crashing on this part of the code. If I comment out this entire bit of code, then everything else compiles and runs fine. gapi.client.init(class apiKey = '*****yAlr4k8Qkb8MpbjSbGBIi5h9067lZ4b5Cs'; discoveryDocs = ["https://www.googleapis.com/discovery/v1/apis/gmail/v1/rest"]; clientId = '*****3111041-b3sfpthnis4ofc94d4qg9eo93q9rd7co.apps.googleusercontent.com'; scope = 'https://www.googleapis.com/auth/gmail.send'; end); I am getting this error: Uncaught #<Object> [line #103] Yes, the astrisks are there to mask my keys , i am using my full key and clientId if I comment out the ClientId and Scope, it will also compile and run without errors gapi.client.init(class apiKey = '*****yAlr4k8Qkb8MpbjSbGBIi5h9067lZ4b5Cs'; discoveryDocs = ["https://www.googleapis.com/discovery/v1/apis/gmail/v1/rest"]; //clientId = '*****3111041-b3sfpthnis4ofc94d4qg9eo93q9rd7co.apps.googleusercontent.com'; //scope = 'https://www.googleapis.com/auth/gmail.send'; end); However, if I uncomment just the clientId out of those two, then i get this message: client_id and scope must both be provided to initialize OAuth. [line #71] so, then i uncomment the scope and again, i get the uncaught object error message
  27. IgorSavkic

    NodeJS file utils and native app

    Thanks, David and Nico, this will be a good starting point to experiment and get going.
  28. DavidRM

    NodeJS file utils and native app

    Here's my example: Files := TW3NodeStorageDevice.Create(nil); Files.Mount(nil, procedure (Sender: TW3StorageDevice; Success: boolean) begin if Success then Writeln(PBNRS_FILE_SYSTEM_MOUNTED) else Writeln(Format(PBNRS_ERROR_MOUNTING_FILE_SYSTEM, [Files.LastError])); end ); And reading a file: Files.Load(PBNConfig.HelpFile, procedure (Sender: TW3StorageDevice; Filename: string; Data: TStream; Success: boolean) begin if Success then begin ... end else ... end
  1. Load more activity
×