Jump to content

Farshad Mohajeri

Administrators
  • Posts

    12122
  • Joined

  • Last visited

  • Days Won

    808

Everything posted by Farshad Mohajeri

  1. unit Main; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, uniGUITypes, uniGUIAbstractClasses, uniGUIClasses, uniGUIForm; type TMainForm = class(TUniForm) procedure UniFormShow(Sender: TObject); private { Private declarations } public { Public declarations } LoginDone : Boolean; end; function MainForm: TMainForm; implementation {$R *.dfm} uses uniGUIVars, MainModule, uniGUIApplication, Unit1; function MainForm: TMainForm; begin Result := TMainForm(UniMainModule.GetFormInstance(TMainForm)); end; procedure TMainForm.UniFormShow(Sender: TObject); begin if not LoginDone then begin if WebMode then Hide; UniForm1.ShowModal; end; end; initialization RegisterMainFormClass(TMainForm); end. unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, uniGUITypes, uniGUIAbstractClasses, uniGUIClasses, uniGUIForm; type TUniForm1 = class(TUniForm) procedure UniFormClose(Sender: TObject; var Action: TCloseAction); private { Private declarations } public { Public declarations } end; function UniForm1: TUniForm1; implementation {$R *.dfm} uses MainModule, uniGUIApplication, Main; function UniForm1: TUniForm1; begin Result := TUniForm1(UniMainModule.GetFormInstance(TUniForm1)); end; procedure TUniForm1.UniFormClose(Sender: TObject; var Action: TCloseAction); begin MainForm.LoginDone:=True; if webmode then MainForm.Show; end; end.
  2. Adding series at runtime is not supported. You can modify an existing series though.
  3. Farshad Mohajeri

    Doubts

    Please send a working test case demonstrating your issue.
  4. Thank you. You can use ComboBoxes with pre-filled items. Of course, filling more complex structures like an address field needs more comprehensive client side coding. What type of auto-fill is your requirement? It is not within scope of uniGUI so it doesn't provide a reporting tools. You can successfully integrate any reporting tool with uniGUI. I personally use Fast reports with success. uniGUI has a visual special set of components which majority of them are based on Ext JS components. uniGUI has been closed source to the public and the receipt to create new components hasn't been shared yet. The reason for this is internal changes to the framework core which wlll be fixed in 0.90.0. Again, some of our developers have been able to create custom components which you can see in related section in our forums. At the correct stage when framework core is fixed the instructions to create custom component will be available. As for non-visual components the main criteria here is thread safety. Component must be completely thread-safe. Which means multiple instances of same component should be usable in several threads which run simultaneously . Our small company is based in Ankara/Turkey and is registered under name of FMSoft. F & M are initial letters of company owners' first names. One can assume that F & M are my name and surname , but that assumption is wrong Yes, I'm aware that company detailed info is not explicitly mentioned anywhere. Main reason is that product is still beta and current focus is 99% on product quality. I'm the main creator of the project and for the most of the part the only developer working directly on the product. Our other developers have been working on products based on uniGUI, not on the framework itself. Our main purpose of creating uniGUI was porting our end-user consumer desktop apps to the web. i.e. we created the uniGUI for ourselves in the first place. There are plans to increase number of people who work on various sides of the framework. Again, I'm waiting for 0.90.0. Thanks
  5. It seems to be using a scripting solution instead of native code.
  6. Your test case works perfectly here. Are you using latest uniGUI build?
  7. Why don't you simply start a new Form and create all menu items instead of modifying same menu of same form?
  8. Haven't u tried this: UniMainMenu1.Items.Clear; Quite easy!
  9. Try this: For I:= UniMainMenu1.Items.Count-1 downto 0 do UniMainMenu1.Items[i].Free;
  10. UniSession.SendResponse('{Json code}', False); False is to disable eval()
  11. For I:= 0 to UniMainMenu1.Items.Count-1 do UniMainMenu1.Items[i].Free;
  12. Workaround: procedure TMainForm.UniButton1Click(Sender: TObject); Var T:TUniMenuItem; Begin T:=TUniMenuItem.Create(Self); T.FreeOnRelease; T.Name:='T1'; T.OnClick:=Test1.OnClick; T.Caption:='T1'; UniMainMenu1.Items.Add(T); // call add here end;
  13. What is ApplMainForm? We don't have such a default Form. procedure TMainForm.UniButton3Click(Sender: TObject); Var T:TUniMenuItem; Begin T:=TUniMenuItem.Create(Self); <------------------------------ end;
  14. First problem I see is that MenuItem owner must be a Form. T:=TUniMenuItem.Create(UniApplication);
  15. uniGUI data events has the following format: /HandleEvent?IsEvent=1&Obj=O24&Evt=data&_S_ID=leA1AthqoO535aE If you generate an equivalent event in same format it will be caught in Delphi OnAjaxEvent handler S_ID is ID for current session. Below function is defined in uniExtUtils.pas function GetEventUrl(Obj: TExtObject; Event: string):string; You can use it to generate a custom URL for a custom data request. MyDataUrl := GetEventUrl(UniGUIControl.ExtControl, 'MyData'): UniGUIControl is the Control which will handle the data request in its OnAjaxEvent event.
×
×
  • Create New...