{"id":31007644,"url":"https://github.com/fafalone/ucanigifex","last_synced_at":"2025-09-13T03:11:32.438Z","repository":{"id":288150003,"uuid":"963303579","full_name":"fafalone/ucAniGifEx","owner":"fafalone","description":"ucAniGifEx Animated Gif Control","archived":false,"fork":false,"pushed_at":"2025-04-23T07:57:04.000Z","size":30180,"stargazers_count":7,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-10T11:11:36.625Z","etag":null,"topics":["activex-control","animated-gif","animated-gifs","com","com-control","direct2d","gif","gif-animation","gif-animations","gifs","twinbasic","usercontrol","vb6","vba","wic","windows-imaging-component"],"latest_commit_sha":null,"homepage":"","language":"Visual Basic 6.0","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fafalone.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-04-09T13:25:48.000Z","updated_at":"2025-04-24T09:11:09.000Z","dependencies_parsed_at":"2025-04-15T20:44:49.235Z","dependency_job_id":null,"html_url":"https://github.com/fafalone/ucAniGifEx","commit_stats":null,"previous_names":["fafalone/ucanigifex"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/fafalone/ucAniGifEx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fafalone%2FucAniGifEx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fafalone%2FucAniGifEx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fafalone%2FucAniGifEx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fafalone%2FucAniGifEx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fafalone","download_url":"https://codeload.github.com/fafalone/ucAniGifEx/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fafalone%2FucAniGifEx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274911885,"owners_count":25372538,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-13T02:00:10.085Z","response_time":70,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["activex-control","animated-gif","animated-gifs","com","com-control","direct2d","gif","gif-animation","gif-animations","gifs","twinbasic","usercontrol","vb6","vba","wic","windows-imaging-component"],"created_at":"2025-09-13T03:11:30.487Z","updated_at":"2025-09-13T03:11:32.412Z","avatar_url":"https://github.com/fafalone.png","language":"Visual Basic 6.0","readme":"# ucAniGifEx v1.1.3\nucAniGifEx Animated Gif Control\n\n![ss](https://github.com/user-attachments/assets/ad8fcf31-6807-4193-9550-4b00f8b19a91)\n\n**ucAniGifExTest.twinproj** - Project with test form shown in the picture above. Requires twinBASIC Beta 734 or newer since the gif file list box gives paths with a backslash in prior versions.\n\n**AniGifEx.twinproj** - ActiveX control project to build .ocx versions for VB6/VBA/etc\n\nSee [Releases](https://github.com/fafalone/ucAniGifEx/releases) for binaries.\n\n**PROJECT UPDATED:**\\\n(v1.1.3, 15 Apr 2025) DisplayGifFromURL, Click/DblClick events, ResetPlayback\n\n(v1.0.1, 09 Apr 2025) Quick fix for various looping issues, see Readme below.\n\n```\n/********************************************************************************\n    ucAniGifEx v1.1.3\n    by Jon Johnson, ported from Windows SDK WicAnimatedGif example, with\n         corrections, additional features, and conversion to control.\n    (c) 2025. Distributed under the MIT License.\n    \n    This is a followup to my ucAniGif control, which while it had very \n    simple code, there were a number of flaws. Some were mistakes that could\n    be fixed, but others were limitations of the underlying GdiPlus code or\n    impractical to fix in the shell interface (I already was resorting to\n    patching assembly instructions in memory to fix the slow playback bug!).\n    \n    Many gifs did not play right, or at all. And very limited extras.\n    \n    While the code here is significantly more complex, this control supports \n    every gif I've found, but it's just as simple to use from the outside \n    while adding some basic enhancements.\n        \n    Features:\n      -Multiple options to display a gif: \n         StartupFile property - Loads and plays a gif file from disk on load\n         DisplayGifFromFile - Loads and plays a gif file from disk on call\n         DisplayGifFromResource - Loads and plays a gif file from the project\n              resources. Specify the ID and group; LoadResData is used.\n         DisplayGifFromMemory - Play direct from a byte array containing a \n              complete gif file.\n         DisplayGifFromURL - Play from an http:, https:, or ftp: resource.\n      \n      -Paused property can suspend/resume playback, StopPlayback, \n          ResetPlayback commands.\n      \n      -Will be transparent to the control BackColor; it's recommended you set\n       this before playing, i.e. ucAniGifEx1.BackColor = Me.BackColor, then play.\n      \n      -Gif is scaled to the control size by default.\n      \n      -PreserveAspectRatio option, with centering in the frame\n      \n      -SizeToFit - Resizes the control to the gif size. Scaling is disabled.\n      \n      -LoopControl - Override the gifs default to force infinite loops or only\n          play once.\n      \n      -LoopEnd, PlaybackEnd, and FrameStep events. Note: FrameStep is disabled\n          by default, to receive it, set EnablePerFrameEvents to True.\n      \n      -AdvanceByOneFrame - If paused, advance by a single frame without resuming.\n      \n      -FrameCount, FrameIndex, ImageWidth, ImageHeight properties.\n    \n      -Supports DPI Aware apps\n      \n    Requirements:\n      Windows 7 or newer\n      \n    Known issues:\n      twinBASIC currently displays a continuable exception error in the IDE. This\n      does not seem to be impacting the control. A bug report has been filed.\n      \n    Change log: \n      (15 Apr 2025, v1.1.3)\n          -Added DisplayGifFromURL to play from http: https: and ftp:\n          -Added Click and DblClick events\n          -Added ResetPlayback method to restart animation from first frame.\n          \n\n      (09 Apr 2025, v1.0.1)\n          -To match modern browsers, gifs without looping info will only play once.\n          -Bug fix: Loop control override not properly implemented.\n          -Bug fix: Missing ByVals in loop metadata lookup caused all gifs to loop \n                infinitely; could possibly cause crash.\n       \n      (08 Apr 2025, v1.0) - Initial release.\n      \n    Thanks\n      Special thanks to bahbahbah (whose code I wound up using), jpbro, and \n      The trick for helping me sort through some scaling issues.\n      And wqweto for helping me out with some C++ issues to get the original\n      SDK example working so I could compare.\n*********************************************************************************/\n```\n\n### How to install and select for use in VBA\n\n#### From binaries\n\nThere's already-compiled binary builds available under the 'Releases' link on the right side column of this page, [or click here](https://github.com/fafalone/ucAniGifEx/releases) to go directly to the Releases page. The  zip contains a win32 folder and a win64 folder, you need to use the one that matches Office for 32bit or 64bit. Once you've extracted the one you need, if it's 32bit, drag/drop `AniGifEx.ocx` in Explorer onto the `regsvr32.exe` in the Windows\\SysWOW64 folder. For 64bit, drop on the one in Windows\\System32 (unless you're using 32bit version of Windows, then just that too).\n\n\u003e [!TIP]\n\u003e If you don't know whether you have 32bit or 64bit Office, go to File-\u003eAccount then click 'About Excel/Access/etc'\n\n\n#### From source\n\nAs noted above, this project was written in twinBASIC. If you don't have it already you can download it from [here](https://github.com/twinbasic/twinbasic/releases). Just download and extract, there's no installer. The Community Edition is free, and will build both 32bit and 64bit OCXs-- the only limitation being that the 64bit OCX will display a splash screen for tB when it loads. The OCX in the Releases section here will not as I've got the Pro version.\\\nYou need the AniGifEx.twinproj file from the source code files of this repository. That contains the entire project, the other files are for browsing the source code in your browser or the ucAniGifExTest.twinproj file is a demo of using the control within twinBASIC. Use the 'Browse' option to open the .twinproj file, in the bottom left of the opening dialog when you launch twinBASIC. After that, look in the toolbar for a dropdown list that says 'win32'... that means it will compile as 32bit. Select win64 from the dropdown to compile as 64bit. After that, click on File-\u003eBuild. It will create and automatically register the OCX, you're all set to open Office and start using it\n\n#### Finding it in VBA\n\nOnce you've done one of the options above, `AniGifEx` should be available in the Tools-\u003eAdditional controls dialog when you're editing a UserForm in Excel VBA, or 'ActiveX Controls' in the Access form designer-- the menu that pops up from the dropdown button on the righthand side of the built-in controls box.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffafalone%2Fucanigifex","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffafalone%2Fucanigifex","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffafalone%2Fucanigifex/lists"}