Questions tagged [lazarus]

Lazarus is an open-source multiplatform RAD environment for the Free Pascal compiler, in the spirit of Delphi, with which it has a fairly high degree of compatibility.

Lazarus is a an open-source multiplatform RAD environment for the Free Pascal compiler, in the spirit of Delphi, with which it has a fairly high degree of compatibility.

See http://lazarus.freepascal.org

1306 questions
-2
votes
1 answer

Lazarus MySQL connect failed

i have normal local server running with MySQL , PHP ,... I tried to write a Lazarus programm to enter stuff in the SQL. I can access from every computer in my network the PHPMyAdmin page under http://192.168.1.119:8888/phpmyadmin/ So my Lazarus…
Tim
  • 1
  • 1
-2
votes
1 answer

Find block number and floor by flat number

Imagine - there's a house with 80 flats. It has 4 floors and 5 blocks. Each block has 4 flats. User is asked to input flat number and Pascal program is supposed to calculate and output flat number. This must be calculated using some kind of formula.…
Gustavs R
  • 61
  • 1
  • 8
-2
votes
2 answers

Change title bar color and buttons

I would like to change title bar in my application. I have no idea how should I do. Can you help me? I found many examples in Delphi but doesnt work in Lazarus. How should I start, what I should do to change for example title bar colour or buttons?
Mlody87
  • 425
  • 1
  • 7
  • 19
-2
votes
1 answer

Displaying Total of spinedit values in a List Box

I am obviously new to Delphi but I just cant seem to figure this simple in out. I need to be able to click the button ' Total for the day ' and this should add the 3 spinedit values and display the total in a List Box.
-2
votes
1 answer

Right Click MainMenu

Having problems with making so when you use right click on mainmenu or Form1 it works and open the specific submenu with Forest,Sea,Clouds and ignores the Pictures ,Exit Menu. Here you cans see the MainMenu: unit Unit1; {$mode…
Deivids
  • 45
  • 1
  • 5
-2
votes
2 answers

How to use an external library in my component?

I created a component , and I need to use IdHttp component (Indy) in it, so first I installed Indy in my IDE,I created the component and istalled it, then I added to uses the unit IdHttp so I can use IdHttp in my component. But, when I compile the…
Safa
  • 485
  • 2
  • 5
  • 24
-2
votes
1 answer

Delphi: Project raising External: SIGSEGV

I have a graphical program with forms and a lot of code. When I started it, it was fine, no errors, no exceptions. I added two more procedures and it still ran without problems. I placed a progress bar, and added this code to an Image's OnClick…
TheGreenOmega
  • 123
  • 1
  • 1
  • 14
-2
votes
1 answer

Lazarus/Delphi: Msg.CopyDataStruct not recognized

I'm new to Delphi and I try to write an experimental plugin for a program in Lazarus. I found a free source code from a different plugin and I try to base on it. My plugin should received the message sent by the program and insert a string into an…
Krzychu
  • 121
  • 7
-2
votes
1 answer

Lazarus. How to invoke inherited method of dynamically created instance?

I've searched this and that and didn't find my situation. I have some variable of a type TCustomControl: var fcontrol:TCustomControl; Then I use some RTTI magic to create instance of different classes-descendants of TCustomControl: constructor…
-2
votes
1 answer

Strange behaviour when simply adding strings in Lazarus - FreePascal

The program has several "encryption" algorithms. This one should blockwise reverse the input. "He|ll|o " becomes "o |ll|He" (block length of 2). I add two strings, in this case appending the result string to the current "block" string and making…
-2
votes
1 answer

Get Length of TStrings List in Lazarus

I have a TListBox called ListBoxPlayers, and I believe ListBoxPlayers.Items references the list of TStrings inside the TListBox. I am trying to use this function but it doesn't seem to work. Any ideas? EDIT: So I'm trying to set the size of the…
user2412643
  • 153
  • 1
  • 1
  • 13
-2
votes
1 answer

Drawing rectangle with canvas

With this code I want to draw a rectangle: procedure TForm1.Button1Click(Sender: TObject); var rectangle:Trect; begin fx:=400; fy:=400; sc1:=base/fx; sc2:=altezza/fy; sc:=max(sc1, sc2); lx:=fx*sc; ly:=fy*sc; xc:=base/2; …
C P
  • 35
  • 1
  • 4
-3
votes
1 answer

How to set specific Date to the DateTimePicker in Pascal(Lazarus) ? I need set a 01.01.1991 for example? Can't find info about it

Certain date into DateTimePicker (Pascal) How to add a certain and specific date into DateTimePicker in the Pascal/Lazarus ?
Olek
  • 1
-3
votes
1 answer

Function to retrieve CPUID does not compile in LAZARUS

I'm trying to port some code from old Delphi7 to Lazarus but following code just won't compile. Lazarus always complains about unknown identifiers. function GetCPUID(Leaf, Subleaf: Integer): TCPUID; begin asm {$IF Defined(CPUX86)} push ebx push…
Atak_Snajpera
  • 619
  • 9
  • 24
-3
votes
1 answer

calling a visual studio dll from delphi or lazarus

I need to call a dll from delphi 7 or lazarus. The information on the dll is minimal but I have an example of its use in visual studio: Declarations: [DllImport("landwell.dll", EntryPoint = "PTcomm", CharSet = CharSet.Auto)] public static…