Jump to content

Dave Nottage

Members
  • Content Count

    1489
  • Joined

  • Last visited

  • Days Won

    36

Everything posted by Dave Nottage

  1. Dave Nottage

    DelphiTwain on 64-bit

    That is correct. This is what I mean: https://docs.microsoft.com/en-us/windows/win32/termserv/virtual-channel-client-dll So yes, RDS; I'm just used to the other terminology. As above, the DLL is on the same machine as the Twain driver. RDS loads the DLL when a session is started to the remote application, which communicates to the virtual channel client DLL via RDS. The remote application notifies the virtual channel to scan an image, and the DLL makes calls via the Delphi Twain code to enumerate the sources, and start scanning an image. The scanning "in progress" dialog shows OK, however the code fails in TTwainSource.ReadNative, as described earlier. The identical code to allow the user to select the source and start the scan works in a DLL loaded by a test app; it fails in the virtual channel client (RDS) DLL. I just hoped someone might know why there's a difference, because debugging isn't telling me anything other than Windows claiming that the handle is invalid.
  2. Dave Nottage

    UDP multicast issues

    Well, it has now come "off the shelf", however not so good news: I'm now unable to make it receive on anything other than Windows (tried iOS, macOS and Android). Sending works from any platform. I swear it was all working before. In any event, I've now made it public, here: https://github.com/DelphiWorlds/Multicaster
  3. Dave Nottage

    DelphiTwain on 64-bit

    It came from this call in the TTwainSource.TransferImages method: rc := Owner.TwainProc(AppInfo, @Structure, DG_IMAGE, DAT_IMAGENATIVEXFER, MSG_GET, @hNative) (TwainProc is the method exported by the Twain DLL) The more pertinent question is: why does it return a valid handle in a DLL that is not loaded by WTS, and why is it apparently invalid in a DLL loaded by WTS? I figured there might be something else I need to do to ensure that it returns a valid handle in WTS.
  4. Dave Nottage

    DelphiTwain on 64-bit

    I discovered that it is throwing an AV at this part of TTwainSource.ReadNative: DibInfo := GlobalLock(Handle); ColorTableSize := (DibNumColors(DibInfo) * SizeOf(RGBQUAD)); // <---- AV here when it calls DibNumColors, as DibInfo is nil The code is inside a DLL written for Windows Terminal Services. The same code works fine in a DLL that is just loaded via a plain application, so perhaps it has something to with WTS? If I call SysErrorMessage(GetLastError) after the GlobalLock, the message is: The handle is invalid. The value for Handle is non-zero.
  5. Dave Nottage

    10.3.2 as next or waiting for 10.4?

    I'm guessing sometime close to next Wednesday: http://blog.marcocantu.com/blog/2019-july-whatsnew-1032-webinar.html
  6. Dave Nottage

    DelphiTwain on 64-bit

    Delphi Rio 10.3.1, VCL. I was having problems with refactored code based on the original. I went back to the very original code and managed to make it work, so something must have gone awry in the refactor. Next time it is refactored there'll be incremental testing 🙂 Next issue is: when it is used in a DLL, the app locks up after the scan has completed.
  7. Dave Nottage

    New Inline variables mess up IDE

    ..or not declare vars inline 🙂
  8. Dave Nottage

    UDP multicast issues

    I managed to make UDP multicast work to my satisfaction (with both IPv4 and IPv6) with Indy a while ago.. had to jump through a bunch of hoops to make it happen. My work has been "sitting on a shelf" waiting for funding for the project(s) it may be used in, but I could turn it into some building blocks for anyone who's interested. One of the things I had to overcome was the lack of multiple bindings in TIdIPMCastServer - a pretty basic omission. Others were: local address changes (because of one or more networks being unavailable etc), dealing with IPv6 only networks (a must for iOS), and discovering local addresses on Android (which Indy does not do yet, unless it has changed recently) I've tried a number of network libraries including ICS, but Indy is still the least painful to work with. Much kudos to Remy.
  9. Dave Nottage

    Publishing iOS apps

    If there is a "Show expired certificates" menu item under the View menu in the Keychain Access app, please click it, and delete any expired certificates.
  10. Dave Nottage

    Publishing iOS apps

    Which means it cannot find a matching certificate for the provisioning profile. Please ensure that the provisioning profile you are using actually *has* the iOS Distribution certificate assigned to it. To do this, go to: https://developer.apple.com/account/ Log in, go to Certificates, IDs and Profiles, select Profiles section, and select the profile for rexpressmanager (make sure it's actually an App Store profile), and check which certificate is assigned to it (bottom left of the info). If it's not an App Store profile, you'll need to create one.
  11. Dave Nottage

    Publishing iOS apps

    I should have also asked what you mean by this, i.e. is there an error thrown in the IDE? If so, please give all the details. If not, at what stage is it a problem? Using Application Loader?
  12. Dave Nottage

    Publishing iOS apps

    Please describe what gives you the impression that one is installed. One way is to use the Keychain application on the Mac, select login in the keychains list, and My Certificates in the category list. There should be at least one iPhone Distribution certificate. Check the expiry date that it has not expired.
  13. Dave Nottage

    DelphiTwain on 64-bit

    It works for Win32, and reports the following sources: Brother DS-620 WIA-Apple iPhone (my iPhone) WIA-Galaxy Tab Active2 (an Android device connected to the computer) For Win64, it errors, as per my original post
  14. Dave Nottage

    DelphiTwain on 64-bit

    Yes, TWAINDSM.DLL is 64 bits. From here: https://github.com/twain/twain-dsm/tree/master/Releases/dsm_020402/windows/64 Though I've now tried those from the link you gave, with the same result. In case anyone asks: I have already also verified that the correct DLL is being loaded by using GetModuleName for the handle returned.
  15. Dave Nottage

    DelphiTwain on 64-bit

    Yes, since as I said, it loads the driver OK. The problem comes after that
  16. Dave Nottage

    Any tips to speed up Android linking and deployment?

    With that issue, usually restarting the device resolves it, for me.
  17. Dave Nottage

    Android Log Capture

    I have ADB log capture in Codex: https://www.delphiworlds.com/codex/ Sorely needs updating because there's a few quirks.
  18. Dave Nottage

    ActivityDialog on Android

    Between then and now? Yes. Entirely dead? No.
  19. Dave Nottage

    ActivityDialog on Android

    Yes: some reproducible code
  20. Dave Nottage

    Upcoming Events issue..

    It's not just you. My guess is whatever feed it is, is down
  21. From Atanas' message: "We realize this is a change to previous operations and to reduce the impact to development projects, we issued a one-time registration limit increase for all customers who are close to hitting their registration count limit. This should address issues with re-installs of your licensed software on existing or new machines. Further, we will continue to look for options to make this more seamless through automation." That means you should have received a bump. If you haven't received one, please contact EMBT. Unfortunately I don't have a direct contact point at the moment for this issue.
  22. I've been successfully (up until now) using the .NET COM interop: https://raw.githubusercontent.com/project-jedi/jcl/master/jcl/source/windows/mscorlib_TLB.pas (as part of JCL) however I'm having trouble invoking a method that is declared with a number of overloads in an assembly. It raises an error "Method xxxx not found", and I'm assuming it is because it does not know which method to use. Regardless, I'd like to be able to use one of the GetMethod calls to find the right overloaded method, probably using GetMethod_5, since I just want to find the method by the name and the parameter types. The question is: how do I go about passing the correct values for the types parameter? If it were using reflection in C#, it would use typeof, so what might be the equivalent in Delphi?
  23. Dave Nottage

    Using GetMethod functions in the .NET COM interop

    I think I've found the way: using the GetType_2 method of _Assembly.
  24. Dave Nottage

    Git UI tools

    SourceTree, on Mac
  25. Dave Nottage

    The Android 64bit deadline warnings have started

    Existing apps will not be not removed until 2021: https://android-developers.googleblog.com/2019/01/get-your-apps-ready-for-64-bit.html The August 1, 2019 requirement is for updates and new apps.
×