Re[2]: running inside Delphi IDE

2005-06-06 Thread Wilfried Mestdagh
Hello Robert, RM I've also written quite a few tray-based applications, but have RM never experienced any particular problems debugging them. What problems are RM you having exactly? Sorry I explained not good :( I have no problem debugging, I just want my program to behave different in

create excel workbook in Delphi

2005-06-15 Thread Wilfried Mestdagh
Hello, I want to create an Exel in Delphi. Using following code: uses ComObj; var ExcelApp: OLEVariant; begin ExcelApp := CreateOleObject('Excel.Application'); I get an invalid class string. I have no Excel installed. Could it be that the object is only accessable after installing Excel ?

Re[2]: create excel workbook in Delphi

2005-06-15 Thread Wilfried Mestdagh
Hello Fredrik, Thanks for the answer and the url's FL Yes, you must have Excel installed since it automates Excel. Yes in fact it is logic of course :) Hmm I found an office update CD, but it refuse to install in my develop machine. Very annoying. However I can install it on an old machine,

user directory

2005-06-15 Thread Wilfried Mestdagh
hi, how to find user directory ? I know it must be somewhere in registry, but in witch key ? --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org http://www.elists.org/mailman/listinfo/delphi-talk

Re[2]: Convert C-Builder program to Delphi?

2005-07-19 Thread Wilfried Mestdagh
Hello W., WD Now having problems with Winsock functions and WD associated pointers. For some reason, I can't WD seem to recv data uncorrupted. I've WD tried it using a string buffer and as a PChar. A Delphi string as whell as a pointer (like PChar) may contains as many NULL as you want,

Re[2]: Convert C-Builder program to Delphi?

2005-07-21 Thread Wilfried Mestdagh
Hello, WD SetLength(LilBuf, 4096); WD Cnt := Winsock.recv(MySocket, LilBuf[1], BytesRead, 0); This is wrong, recv expect there the max size it may fill in the buffer, so it should be: Cnt := Winsock.recv(MySocket, LilBuf[1], 4096, 0); BTW for winsock communication I use TWSocket

insert text at cursorposition in TMemo

2005-08-22 Thread Wilfried Mestdagh
Hello, I need to insert text in a TMemo at the current cursor's position in that memo. Someone knows how to find out where the cursor position is ? --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org

ShellExecute from out of a NT service

2005-08-24 Thread Wilfried Mestdagh
Hello, I have a server application which runs hidden and shows a tray icon. Clicking on the tray icon start another application (to configure the server). It is separate aplication because it also has to run on remote machine. Now the problem: To run the second program I use ShellExecute(0,

Re[2]: ShellExecute from out of a NT service

2005-08-24 Thread Wilfried Mestdagh
Hi Bob, Thanks for reply. I found solution. I only had the exeName of the application in the ShellExecute. It seems that an NT service is not aware of the folder where it is running. Including full path did help: ExtractFilePath(Application.ExeName) + TheExeName --- Rgds, Wilfried

NT service and tray icon on remote desktop

2005-08-24 Thread Wilfried Mestdagh
Hello, When I have a NT Service that needs a tray icon when a user logs in I normally have a timer peridically checking for taskbar window. What about remote desktop ? How to detect a remote login and display a tray icon. Some hin very welcome because I have no idea what to check for. --- Rgds,

Re[2]: NT service and tray icon on remote desktop

2005-08-24 Thread Wilfried Mestdagh
Hello Bob, BS desktop, and I think Wilfried wants to display the tray icon in that BS particular remote desktop as well... Yes correct. If nobody is logged in on the machine itself and there is a remote login then I have to do the icon display for eventually start the client configuration

Re[2]: NT service and tray icon on remote desktop

2005-08-24 Thread Wilfried Mestdagh
GB If you find an answer to this, please let us all know. I couldn't find GB it. Of course :) --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org http://www.elists.org/mailman/listinfo/delphi-talk

Re[2]: NT service and tray icon on remote desktop

2005-08-24 Thread Wilfried Mestdagh
Hello Brad, GB I finally created a custom message and built a small program that sends GB the message to the NT Service message loop which tells it to show the GB icon. It was the only way I found. How? I recall me creating a hidden window in a service to send a custom message to from within a

Re[4]: NT service and tray icon on remote desktop

2005-08-24 Thread Wilfried Mestdagh
Hello Brad, GB I couldn't find the window either using terminal services, but had no GB problem using Remote desktop : Tryed it again, and it works as a glance :) Strange I was pretty sure this was not working, maybe I did that test (long ago) in a moment of low (brain) batteries :) Anyway I

Re[6]: NT service and tray icon on remote desktop

2005-08-27 Thread Wilfried Mestdagh
Hello Jack, What I do is at regulary intervals (30 seconds) check if the taksbar is there: FindWindow('Shell_TrayWnd', nil); If it is then destroy the timer and create the trayicon. Also when User log's off the way around. You find an example on my site together with a little class to create an

code completition building components

2005-09-08 Thread Wilfried Mestdagh
Hello, When you make a component and type new procedure then shift-ctrl-c will build the complete procedure for you. All this is done nice alphabeticaly which I like. Now I'm in the middle of a component ant certainly it make the new procedures NOT alphabeticaly anymore but put them in bottom of

Re[2]: code completition building components

2005-09-08 Thread Wilfried Mestdagh
Hello David, [Delphi 5] If you added any new procedures yourself, be sure to add them and keep them in purely alphabetic order. You where right. I did doublechecked it, and there was 1 procedure out of alphabetic order. Already a long time and certainly it begins... I put the one in right

TMemo finding out if a vertical scrollbar is needed

2005-09-15 Thread Wilfried Mestdagh
Hello, I want to add lines to a TMemo without scrollbars. But if needed (if count of lines is over height of the TMemo) then I want to set the vertical scrollbar. But how to know or calculate when this scrollbar is needed ? --- Rgds, Wilfried http://www.mestdagh.biz

Re[2]: //Debugging?

2005-09-15 Thread Wilfried Mestdagh
Hello Rob, That won't really solve anything. It will _always_ detect a debugger, even when one isn't present. You rigth. I realized this after my post :( --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list -

Re: TMemo finding out if a vertical scrollbar is needed

2005-09-17 Thread Wilfried Mestdagh
Hello, I do it at the moment this way. However it does not seem correct. It seems the Height does not taken into account the free dots above each line. In my application I just add 4, but I gues this is depending on font. Someone has a better idea ? procedure CheckScrollBar(Memo: TMemo); begin

finding out when application is minimized and tray icon

2005-09-19 Thread Wilfried Mestdagh
Hello, i want to active and show the form when user minimize my program Use Application.OnMinimize event. and i want show icon of my program in the right task bar same as antiviruse programs You find a free TrayIcon component on my website. --- Rgds, Wilfried http://www.mestdagh.biz

Re: time calculation

2005-10-09 Thread Wilfried Mestdagh
Hello Pakhrul, how can i count the time between two ttimers? If I understeand your question right you wants to know the current value of a timer, meaning how mutch time already elapsed or still to go until it fires, right ? If this is the case then as far as I know the answer is no :( However

Re: Adding a field to a ClientDataSet at runtime

2005-10-11 Thread Wilfried Mestdagh
Hello Brad, Does anyone know how to add a new field to a ClientDataSet after the DataSet is already created? Is it possible? Dont know, but I use TKbmMemTable from Kim Madsen http://www.components4developers.com which is very good and can indirecly do this at runtime (by saving the data to a

Re: TVarRec

2005-10-11 Thread Wilfried Mestdagh
Hello Brad, I have two ClientDataSets with identical fields. One is for the user viewing the data, and the second receives incoming data, processes it, filters out unwanted records and then adds the remaining records to the other ClientDataSet so the user can view them. The TKbmMemtable I

Re[2]: Adding a field to a ClientDataSet at runtime

2005-10-11 Thread Wilfried Mestdagh
Hello Brad, Thanks. I might try it. I've had the TKbmMemTable for many years, but haven't used it for at least a couple of years. It is still a remarkable good product, and has excellent support on a news server latest time. I'm not sure I know how to add a field in a stream, but I guess I

Destroy exception object

2005-10-20 Thread Wilfried Mestdagh
Hello, I know that an exception handler destroy the Exception object, eg in this case it is automaticly free: try if Condition then raise Exception.Create('Foo'); except on E: Exception do TriggerError(E); end; But question is what in this case: if Condition then begin E :=

Re[2]: Destroy exception object

2005-10-20 Thread Wilfried Mestdagh
Hello Rob, However, the name of your TrigerError procedure doesn't seem right. You're not really _triggering_ the error in that procedure. The error has already occured, and you're telling the procedure what the error was. I use TriggerXXX in my objects to Trigger an event. For example:

compiler warning

2005-10-23 Thread Wilfried Mestdagh
Hello, I have a compiler warning in following code 'F might not be initialized', at the M.LoadFromStream(F); line. M := TMemoryStream.Create; try for n := 0 to FFiles.Count - 1 do begin try F := TFileStream.Create(FFiles[n], fmOpenRead or fmShareDenyWrite); except

Re: compiler warning

2005-10-23 Thread Wilfried Mestdagh
Hello, I changed like this to make the compiler happy: M := TMemoryStream.Create; try for n := 0 to FFiles.Count - 1 do begin try F := TFileStream.Create(FFiles[n], fmOpenRead or fmShareDenyWrite); except TriggerWarning('Could not open ''' + FFiles[n] + );

strange coding

2005-11-02 Thread Wilfried Mestdagh
Hello, By accident a came across a strange coding: if (assigned(loc)) then begin; // somecode end; Note the ';' after the begin ! This compiles fine. Wy ? Is this a minor flaw, or has this some Pascal history ? --- Rgds, Wilfried http://www.mestdagh.biz

Re[2]: Run as normal AND as NT Service Application

2005-11-04 Thread Wilfried Mestdagh
Hello Mark, Check my site. There is a little class you have to include that can run your exe as NTService or normal GUI without changes. very easy for debugging and other purposes. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing

Re: Localization

2005-11-09 Thread Wilfried Mestdagh
Hello Fastream, I use TMultlang. Dont know if it's compatible with D7. I find it very good. http://www.delphifaq.com/e/mlintro.htm You can email the author to ask if it is compatible with D2005+ --- Rgds, Wilfried http://www.mestdagh.biz __

Re[2]: More compiler optimization bugs

2005-11-14 Thread Wilfried Mestdagh
Hello Rob, RK procedure SwapCardinal(var X: Cardinal); RK asm RK mov ecx, [eax] RK bswap ecx RK mov [eax], ecx RK end; RK The BSWAP instruction reverses the order of the bytes in a register. It's RK safe to overwrite ECX without saving its previous value. The parameter RK gets passed in

strange optimization bug?

2005-11-16 Thread Wilfried Mestdagh
Hello, I have a strange optimization bug and I wonder wy, also I wonder if there are similar optimizations in Delphi that I need to know of. I explain with a peace of code: if Foo.CheckForChanges then Foo.SaveToFile; procedure TFoo.CheckForChanges: boolean; var n: integer; begin Result :=

Re[2]: strange optimization bug?

2005-11-16 Thread Wilfried Mestdagh
Hello Francois, Try to disable partial boolean evaluation with option {$B+} Yes that works too. Is nicer solution than with a counter. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org

Re[2]: strange optimization bug?

2005-11-16 Thread Wilfried Mestdagh
Hello Sid, for n := 0 to Count - 1 do if CheckAccount(Items[n]) then result := true; Yes correct, but I just liked the 'or' :) short-circuit evaluation This is probably my english, but this is for me not a short circuit evaluation. eg this is: if a and b and c if a already

IDE stile TMemo with indent

2005-11-16 Thread Wilfried Mestdagh
Hello, I need to make a program with TMemo that automaticly can indent / undent like in delphi IDE. Started a few times with it because I think it is simple but not gotting far :( Someone has written something like this already ? --- Rgds, Wilfried http://www.mestdagh.biz

Re[2]: IDE stile TMemo with indent

2005-11-17 Thread Wilfried Mestdagh
Hello Robert, Why not use the TRichEdit and it's margin and/or tab settings. Just set it to plain text only. I just knew it must be simple :) thx! --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org

Re: calculating memory

2005-12-09 Thread Wilfried Mestdagh
Hello Richard, I want to generate a warning message if the object they load into my software exceeds a limit on what the software can do with current memory and I think GetHeapStatus function will return what you wants. Check also AllocMemCount and AllocMemSize. --- Rgds, Wilfried

Re: nil or Self?

2005-12-31 Thread Wilfried Mestdagh
Hello Dan, The most common if not the best way is to use nil. This because the agreement. In a buttonClick the event handler expect a button but not something else. Of course there can be exceptions but making away from this habitudes can be difficult if you at later time have to do a maintenance

Re[2]: strange alignment

2006-01-10 Thread Wilfried Mestdagh
Hello Human, But anyway, supose I will encounter other situations where I can't use a scroll box. It will be a way to align something to the right before other components aligned to top? Maybe playing around the wht Anchors property ? Dont know if they work similar with all controls like

Re[2]: strange alignment

2006-01-10 Thread Wilfried Mestdagh
Hello Human, H Anchor doesn't work with TSplitter... H ...or else, TSplitter works together with other components only H if that components are aligned and H not anchored. What if you make a panel, having another panel on it right aligned with the TScrollbar. Then another panel client aligned

Re: Year 2000

2006-01-16 Thread Wilfried Mestdagh
Hello Fastream, FT - either days passed since 1,1, 2000 No floating point nececary since you only need days. So: BaseDate, ElapDays: integer; BaseDate := integer(EncodeDate(2000, 1, 1)); ElapDays := Trunc(Now) - BaseDate; --- Rgds, Wilfried http://www.mestdagh.biz

Re[2]: Strings in Delphi should be 2GB, right?

2006-03-04 Thread Wilfried Mestdagh
Hello Human, Also, I discovered that I need to keep the whole report in memory until it is fully built, then I have to sort the paragraphs in a special order. So, writing to disk is excluded. Then you have to do a lot of Move's after the whole buffer is build. To avoid that you can allocate a

Re[4]: Strings in Delphi should be 2GB, right?

2006-03-04 Thread Wilfried Mestdagh
Hello Human, I’m a little bit disappointed. I never imagine it will be so complicated to write a 1-10MB string. This is difficult to optimize. Concatenating strings is in fact ar reallocation of memory. the larger it is the more difficult to find a contiginous block of memory. Suppose at a

Re[2]: TQuickreport

2006-03-07 Thread Wilfried Mestdagh
Hello Stephen, It's not something as simple as the QrDBText's Dataset property not being set, is it? yes it was :( see my oter mail. Thanks for reply :) Beginners fault. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing

Re: The Help File Saga (Amost like Return of the Dreadi)

2006-06-23 Thread Wilfried Mestdagh
Hello Andre, Thank you for sharing experiance. Tryed it and works as a glance. In D7 it generate AV if html help file is still open and application is quit, but this seems only in IDE. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk

Re[2]: hints on multiple lines

2006-06-29 Thread Wilfried Mestdagh
Hello Human, I want to split the EXISTING comments, and still be able to insert the comments in Object Inspector. Use Application.OnHint to get the current hint to display. There is a property Application.Hint witch is assigned the current hint to display. You can check in this event handler

disable keyboard shortcuts temporary

2006-07-07 Thread Wilfried Mestdagh
Hello, I have a main form with mainmenu ans shortut keys to several items. But when I create another form ans show it modal, and I Hide the mainform then the shortcuts are all working in the new form. If I dont Hide the main form then the shortcuts are disabled. For example: procedure

Re[2]: Strange problem with D7 IDE

2006-07-11 Thread Wilfried Mestdagh
Hello Human, I think this is a Windows message not Delphi. Delphi is looking for a folder that can't be found by Windows. Try a 'scan disk' first. You are right. There where some bad sectors. I did checked windows event viewer and saw some disk errors but did not bother because it was a vew

build always certain unit in a project

2006-07-17 Thread Wilfried Mestdagh
Hello, I have a project containing 2 exe's using same units. Some of the units have conditional compilation. To not forget to build, is there a compiler option that a certain unit is compiled always ? --- Rgds, Wilfried http://www.mestdagh.biz __

Re: //Event logging

2006-07-28 Thread Wilfried Mestdagh
Hello Peter, Here is an example. I did some cut/copy from one of my applicaitons to only have the relevant part. I hope it is still working :) About the DLL and all the things you find about the message compiler and so, this is all not true. You only have to set somewhere your application

Re[2]: //Event logging

2006-07-28 Thread Wilfried Mestdagh
Hello Peter, Yes, but to get rid about the funny message you need to set the file/path in registry somewhere. I did a search but could not find it for the moment. It is a while ago and deleted in my brain :) --- Rgds, Wilfried http://www.mestdagh.biz

Re: never-build package

2006-09-28 Thread Wilfried Mestdagh
Hi, Change in the package options 'never build' to 'build as needed'. That should solve it. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org http://www.elists.org/mailman/listinfo/delphi-talk

concatenate pchar with char and convert to string

2006-10-25 Thread Wilfried Mestdagh
Hello, Subject maybe not technically correct, but there is something where I have no explanation for it: procedure Test(const S: string); begin WriteLn(Length(S)); end; procedure TForm1.FormCreate(Sender: TObject); var P: PChar; begin AllocConsole; GetMem(P, 512); FillChar(P^,

Re[2]: concatenate pchar with char and convert to string

2006-10-25 Thread Wilfried Mestdagh
Hello Fred, Because AFAIK, the length of a string is only 256 ... So if not correct typecasted to a string it is truncated to 256 chars ? But can you explain me wy this is ? I should expect a compiler warning in that case. And it is only when concateneting an extra character. for example:

Re: End-user run-time reporting tool

2006-12-08 Thread Wilfried Mestdagh
Hello Cosmin, Since a short time I use FastReports and I am very content of it. You can do everything programatically, but also everything with scripting (pascal, basic, c, java). It is data aware, but not nececary, and you also can use user data objects (eg like we do in Delphi in memory in a

Re[2]: Windows XP network security issue and my Delphi application

2006-12-17 Thread Wilfried Mestdagh
Hello Cosmin, Can you connect to the server using a simple telnet session ? this should be possible if the server uses TCP. If not, what is the winsock error ? (I think you have to use the old telnet.exe W2K or older to get the error number). --- Rgds, Wilfried http://www.mestdagh.biz

Re[2]: Windows XP network security issue and my Delphi application

2006-12-17 Thread Wilfried Mestdagh
Hello Cosmin, From the server machine I can connect to the Firebird server using telnet 127.0.0.1 3050. If I try telent REAL_IP_ADDR 3050 the connection fails! I don't From the same machine as where the fireBird server runs on ? Because this is normally impossible unless there is

Re: Need a good unit for tray icon display

2007-01-27 Thread Wilfried Mestdagh
Hello, component unit for tray icon display with pop-up menu I have a free one on my site. Maybe it fit your needs ? --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org

application directory in NT service

2007-04-30 Thread Wilfried Mestdagh
Hello, Someone know how to get the directory my application is sitting in if running in TService ? --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org http://www.elists.org/mailman/listinfo/delphi-talk

Re: application directory in NT service

2007-04-30 Thread Wilfried Mestdagh
Hello, Got it: GetCommandLine; --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org http://www.elists.org/mailman/listinfo/delphi-talk

typecasting ole object

2007-07-20 Thread Wilfried Mestdagh
Hello, I have a problem typecasting OLEVariant to another object. When I do this in C# it is very simple: object[] vertices = shape.Vertices as object[]; foreach (object vertex in vertices) { loc = vertex as Location; But in Delphi: procedure TForm1.CalcZonesBtnClick(Sender: TObject);

Re[2]: typecasting ole object

2007-07-21 Thread Wilfried Mestdagh
Hello Rob, No, I mean, show us the declaration of Location -- what have you told the compiler a Location is? The error message you got usually means that the interface type on the right does not have a GUID. Thank you for your concern. This is some copy of the type library: // GUIDS

Re[2]: typecasting ole object

2007-07-23 Thread Wilfried Mestdagh
Hello Peter, Before you typecast a variant to an interface, you must typecast it to Iunknown or Idispatch: Loc := IDispatch(Vertex) as Location; Thank you. This works as a glance :) FYI, Below is a unit that allows you to create a 'for each' statement in Delphi. Hmm itgives me

Error creating form in IDE

2007-08-23 Thread Wilfried Mestdagh
Hello, I have a Delphi 7 project, and when I open it then I have on 4..5 forms the error: Error creating form: a call to an OS failed. Typically it is always the same forms. When I then close Delphi, then doubleclick on 1 of the *.dfm files, then it opens in text. When I then rightclick and hit

Re[2]: Error creating form in IDE

2007-08-24 Thread Wilfried Mestdagh
Hello, The problem *may* not be in the (DFM) form file but in the DPR file. I recently posted something related to this. Delphi IDE accused the DFM but the error was in DPR. Yes I remember the post. I will try this. thanks. --- Rgds, Wilfried http://www.mestdagh.biz

code sequence

2007-10-10 Thread Wilfried Mestdagh
Hello, functions are executed from left to right, and it seems so with the WriteLn in atoi function. However this program displays: 1 2 3 3 2 1 wy is it the way around in the function Test ? Can someone explain this technically ? Probably I miss something but I cannot see wy ? function

Re[2]: code sequence

2007-10-11 Thread Wilfried Mestdagh
Hello Ken, example, if it is necessary to stack operand results along the way. In this case the functions may be evaluated right to left so that they can be taken from the stack in reverse order (left to right) to evaluate the expression. Yes thanks. A simple look at the ASM output shows

Re[2]: code sequence

2007-10-11 Thread Wilfried Mestdagh
Hello Ken, On this basis, I don't think I'd want to rely on the calling convention to resolve the function calling order for me. Correct. In this case because the same function call is used to return 3 different values the compiler takes the most optimized and just push the return values on

Re[4]: code sequence

2007-10-11 Thread Wilfried Mestdagh
Hello Ken, Even with 3 *different* function calls, register still calls them right to left, but pascal left to right. yes you right, just test it. And of course it only matters if the function calls are changing something that depend on each others result. thanks for additional info. ---

Waitfor wait forever if used in a dll

2007-12-29 Thread Wilfried Mestdagh
Hello, I have a good working object that create a thread. in the destructor of the object I call a SetEvent to terminate (the Execute uses WaitForMultipleObjects and one of it is a CloseEvent). The thread Execute method terminates normal. SetEvent(CloseEvent); WaitFor or WaitForSingleOjbect with

Re: Waitfor wait forever if used in a dll

2007-12-29 Thread Wilfried Mestdagh
Hello, After writing this mail, I made a function to destroy the objects before unloading the DLL. Then all is normal. Stil the question persists, wy does it not work in the DLL_PROCESS_DETACH ? --- Rgds, Wilfried http://www.mestdagh.biz __

popup menu in tray application

2008-04-07 Thread Wilfried Mestdagh
Hello, I have a little application that display only a tray icon and a menu. While it all works well there is something strange. When you right click then the menu pops up, but you have to click on a menu item to let the menu dissapear. Normally if you press escape or click somewhere els on the

Delphi licence for other user on XP

2008-11-24 Thread Wilfried Mestdagh
Hello, Sometime I have to work remote on my machine. I want to do this with another user with limited rights (a normal user rights) on XP. But when I create another user and login and start Delphi, then Delphi is complaining there is no licence. What is the best way to avoid this? --- Rgds,

Re[2]: Delphi licence for other user on XP

2008-11-24 Thread Wilfried Mestdagh
Hello Francois, Try to copy .borland folder from the registered user profile to the other user profile. yes that did it. thanks. --- Rgds, Wilfried http://www.mestdagh.biz __ Delphi-Talk mailing list - Delphi-Talk@elists.org

calculate with of text while editing TDBGrid

2009-07-31 Thread Wilfried Mestdagh
Hello, When a DBGrid is in insert or edit mode the text typed in is stored somewhere in an internal buffer I guess. I want to get this buffer while typing to calculate the width in pixels of the text. Someone knows how this could be done? Reason: A user fills in a form with a DBGrid. A certain

Re[2]: calculate with of text while editing TDBGrid

2009-08-01 Thread Wilfried Mestdagh
Hello Peter, Thank you, this works perfect. This is some working demo code in case someone needs it: type TMyGrid = class(TDBGrid); procedure TMain.DBGridKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState); var Grid: TMyGrid; begin if DBGrid.SelectedField.FieldName =

Re[2]: WM_ACTIVATE

2009-08-19 Thread Wilfried Mestdagh
Hello Rob, Explain more about what problem you're actually trying to solve. Thank you for your reply. Yes you are right, many times it is better to explain the whole story. What I want to do is following: - I need to make a TAPI interface. The user want to select a part of a text (that is a

Re[2]: WM_ACTIVATE

2009-08-20 Thread Wilfried Mestdagh
Hello Andre, I used GetForeGroundWindow() to do this. Seems I have different results. I create following message handler wich is called on activate and also on deactivate: procedure TForm1.WMActivate(var Msg: TMessage); var PrevWnd, NextWnd, ForegroundWnd: THandle; Title: array[0..255]

RE: Stopping NT service

2010-05-08 Thread wilfried Mestdagh
Hi Marcin, Thank you. I will study this library. Looks a lot... -- mvg, Wilfried http://www.mestdagh.biz http://www.comfortsoftware.be -Oorspronkelijk bericht- Van: delphi-talk-boun...@elists.org [mailto:delphi-talk-boun...@elists.org] Namens Marcin Bury Verzonden: vrijdag 7 mei 2010

Making a Delphi program that inputs the user an password in a browser.

2013-02-26 Thread Wilfried Mestdagh
Hi, I have a very annoying problem. U use Smartschool a lot. That is a web site fro students. The problem is that smartschool in some way clear username and password. So the fields arealways blank, http://cvoprovincieantwerpen.smartschool.be/index.php I'm very tyres of this. I was thinking of