-
WSdane_walther
AskWoody LoungerThanks to both of you for suggestions — however, it seems that even setting Cancel=true on the Unload() event does not actually prevent the form from closing if the table has a required value and does not allow zero-length strings.
I just removed the required setting from the table, and perform my own checks in the form unload() event…. Not ideal, but acceptable.
..dane
-
WSdane_walther
AskWoody LoungerDu-ohhh!! silly oversight.
thanks Hans.
-
WSdane_walther
AskWoody LoungerFYI — I ended up updating the process such that the calling form goes ahead and adds a new entry, preloads some values, saves the new entry (tagging it for later verification), and opens the “edit” form in edit mode; same functionality to the user, same form, same code in the opened form… When they’re done, I call that record back up, and verify that all the data’s good. If so, I keep. If not, I can do whatever (display error, remove the item, etc)
thanks,
..dane -
WSdane_walther
AskWoody LoungerHans — I like the idea of using an unbound form for new items — but are you suggesting to have two identical forms, the difference being that one is bound and one is unbound? Or are you meaning something different?
thanks,
..dane -
WSdane_walther
AskWoody LoungerAWESOME!
Thanks. that is so much nicer an approach.
..dane
-
WSdane_walther
AskWoody LoungerThanks for the suggestion Hans. Worked like a champ..
FYI — I set the .verb to acOLEVerbHide to keep the PowerPoint application from popping up and remaining open even after the slide had been updated..
..dane
-
WSdane_walther
AskWoody LoungerEdited by HansV to provide link to post and to MSKB article – see Help 19
Found post 30459 that has a routine to query WIndows API for the screen resolution…
Found an Microsoft Knowledge Base Article 210590 regarding how to convert Twips to Pixels. Reversed the algorithm to make a PixelToTwip conversion.
Module is attached for anyone to reference…
..dane
-
WSdane_walther
AskWoody LoungerLooks like the following wouldn’t work, because maximizing inherently makes the form visible again…
Me.Visible = False DoCmd.Maximize sglWindowWidth = Me.InsideWidth sglWindowHeight = Me.InsideHeight DoCmd.Restore Me.Visible = True
I don’t see anything in the screen object either, that would tell me maximum available screen size. And furthermore, when you ‘maximize’ a form, it looks like it overlaps the Windows toolbar (at least with Off2k/Win2k). I’d really like the maximum desktop size, not maximum screen size…
ideas?
..dane -
WSdane_walther
AskWoody LoungerThanks… for some reason I thought the .width/height properites were wanting inches instead of twips, so I had the .insidewidth property divided by 1440 (twips in an inch). That’s what went wrong — it was too small!
Next question; is there anyway to learn the maximum screen size withOUT actually resizing a window? Hmm… maybe I can use the .visible property to maximize, grab the size, then go back…. I’ll try and report back.
..dane
-
WSdane_walther
AskWoody LoungerAwesome! I like much better having all the code in the databse vba, not in the embedded object.
Thanks for all your help. Working well now….
-
WSdane_walther
AskWoody LoungerAlright, I’ve stumped myself again.
Sorry if this is a newbie question, but I can’t find anything in the help files…
I’ve gone into PowerPoint and played around with the Polyline object, successfully creating, resizing, and moving it around to get comfortable with the object..
I’m now back in Access, and on a form have added an Object->PowerPoint Slide, which I’ve named pptPreview. I’ve also got a command-button called cmdGeneratePreview. And within the pptPreview slide I’ve even got the subroutine (subDrawPolyline()) included to genreate the polyline shape.
Now — how do I invoke subDrawPolyline() from within the Access command button cmdGeneratePreview?
thanks,
..dane -
WSdane_walther
AskWoody LoungerThanks Charlotte, Hans, and Wendell for all jumping in with suggestions..
Of all the options, I’ll probably look into an embedded Powerpoint slide. I may also look into the suggestion of a report with dozens of line segments… the data is stored as dozens of sets of line segments anyway, so it would not be too difficult to do something like that.
thanks again,
..dane -
WSdane_walther
AskWoody Lounger> But what would be the purpose in a database application?
I never thought you’d ask, Hans…
Fairly simple situation; I am electrical engineer, and develop PCBs as my primary task. Not sure how much you know about PCB design, but in short: I design a PCB, and that PCB has a particular shape to it, with parts all over the place to make it work. All of this data (component locations, rotations, PCB outline, etc) is represented in an Access database generated by the PCB design tool. Once the PCB design is complete, it is put into what’s called a PCB panel, which adds material around the particular PCB outline to make it a retangular shape, so that the machines producing the board can ‘grip’ the panel more easily (simplified). Additionally, a PCB panel can be made very large and include multiple individual PCBs at different angles within the PCB panel (think of a jigsaw puzzle).
As a task secondary to my design role, I’m building a tool to help process PCB panel data (simplified). One feature that is not necessary but would be a really nice addition is a “preview” button that draws a representation of the PCB panel, based on the PCB outlines of each PCB within the panel (each PCB offset and rotated properly as defined within the panel).
I see two possible solutions:
(1) use some sort of external tool (commandline driven, non-GUI), given a set of line segments, to generate a bmp/gif/jpg image of the PCB panel, and then just pop up a window displaying the image. Pros are that I don’t have to write an algorithm, and that it can be done real-time. Cons are that I need an external tool, and currently I don’t know of one that will do that.
(2) utilize something similar to the “Free Form” drawing object found in word, excel, and powerpoint to generate the image myself from the set of line segments. Pros are that I have control over the algorithm and how it is displayed, and can be done real-time. Cons are that I currently don’t know how to invoke a free form shape in Access.
Sorry if that reply’s too long; but I bet you fully understand now what I’m looking to do…
I’ve thought about invoking a powerpoint object, creating a blank slide, and use the powerpoint freeform shape tool to generate the image. But if I could do it without invoking a PowerPoint object, that’d be sweet….
have a great weekend,
..dane -
WSdane_walther
AskWoody LoungerKaren — tried your suggestion (quicker for me, no macros), but I get the following error:
The built in style “xxx” cannot be deleted.
In my situation, I had a paragraph of style “Normal” and underlined and italicized it. When I moved away from the paragraph, it automatically changed the style type to “Heading 7.” Of course this is NOT what I wanted done (or I would have changed the style myself!). As a result, that Style was pulled from the ‘master list’ (I suppose?) of styles into my document. And I therefore cannot remove it…
Am I overlooking the obvoius?
And is there any way to have Word *NOT* automatically change your styles?
thanks!
..daneps.- I am using Word 2000 (not 2002) but felt it was similar enough a topic to piggy-back on this thread…
-
WSdane_walther
AskWoody LoungerTim,
Ah-ha! My newbieness is obviously showing… I didn’t even think about putting different control data on your form. But that’s a very good idea. Theoretically, I could have all of my controls (buttons, listboxes, etc) on a userform, and use the userform’s repaint mechanism. Wow, that’s brilliant.
Well, the tool seems to work now and I think is done. But I will definately consider this route for future tools.
Thanks for all the help everyone,
..dane
![]() |
There are isolated problems with current patches, but they are well-known and documented on this site. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
.NET 8.0 Desktop Runtime (v8.0.16) – Windows x86 Installer
by
WSmeyerbos
4 hours, 48 minutes ago -
Neowin poll : What do you plan to do on Windows 10 EOS
by
Alex5723
32 minutes ago -
May 31, 2025—KB5062170 (OS Builds 22621.5415 and 22631.5415 Out-of-band
by
Alex5723
3 hours, 22 minutes ago -
Discover the Best AI Tools for Everything
by
Alex5723
3 hours, 31 minutes ago -
Edge Seems To Be Gaining Weight
by
bbearren
4 hours, 14 minutes ago -
Rufus is available from the MSFT Store
by
PL1
1 hour, 43 minutes ago -
Microsoft : Ending USB-C® Port Confusion
by
Alex5723
1 day, 4 hours ago -
KB5061768 update for Intel vPro processor
by
drmark
10 hours, 59 minutes ago -
Outlook 365 classic has exhausted all shared resources
by
drmark
7 hours, 10 minutes ago -
My Simple Word 2010 Macro Is Not Working
by
mbennett555
1 day ago -
Office gets current release
by
Susan Bradley
1 day, 2 hours ago -
FBI: Still Using One of These Old Routers? It’s Vulnerable to Hackers
by
Alex5723
2 days, 17 hours ago -
Windows AI Local Only no NPU required!
by
RetiredGeek
2 days, 1 hour ago -
Stop the OneDrive defaults
by
CWBillow
2 days, 17 hours ago -
Windows 11 Insider Preview build 27868 released to Canary
by
joep517
3 days, 3 hours ago -
X Suspends Encrypted DMs
by
Alex5723
3 days, 5 hours ago -
WSJ : My Robot and Me AI generated movie
by
Alex5723
3 days, 6 hours ago -
Botnet hacks 9,000+ ASUS routers to add persistent SSH backdoor
by
Alex5723
3 days, 6 hours ago -
OpenAI model sabotages shutdown code
by
Cybertooth
3 days, 7 hours ago -
Backup and access old e-mails after company e-mail address is terminated
by
M W Leijendekker
2 days, 19 hours ago -
Enabling Secureboot
by
ITguy
3 days, 2 hours ago -
Windows hosting exposes additional bugs
by
Susan Bradley
3 days, 15 hours ago -
No more rounded corners??
by
CWBillow
3 days, 11 hours ago -
Android 15 and IPV6
by
Win7and10
3 days ago -
KB5058405 might fail to install with recovery error 0xc0000098 in ACPI.sys
by
Susan Bradley
4 days, 3 hours ago -
T-Mobile’s T-Life App has a “Screen Recording Tool” Turned on
by
Alex5723
4 days, 6 hours ago -
Windows 11 Insider Preview Build 26100.4202 (24H2) released to Release Preview
by
joep517
4 days, 1 hour ago -
Windows Update orchestration platform to update all software
by
Alex5723
4 days, 13 hours ago -
May preview updates
by
Susan Bradley
4 days, 1 hour ago -
Microsoft releases KB5061977 Windows 11 24H2, Server 2025 emergency out of band
by
Alex5723
3 days, 16 hours ago
Recent blog posts
Key Links
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 |
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.