Easy Transparent Forms with Visual FoxPro

Want an easy way to make your forms transparent in Visual FoxPro? How about a little class to drop on your form.

The TransparentForm class will automagically make your TOP-LEVEL form (ShowWindow = 2) appear semi-transparent.

Note: This works on Top-Level forms running on Windows 2000 or higher only. You won’t see any effect on Windows 98 or on any form that does not have ShowWindow = 2.

Also, this was created with Visual FoxPro 9.0 (it works unchanged in VFP 7 and 8). If you want to run it in VFP 6, you will need to change the references to ThisForm.hWnd.

How do you use it? Drop it on a form, and set the nOpaquePct property to the percentage of opaqueness that you want the form to have (the default is 90).

Here’s a few pictures of the sample form in action:

With 90% ‘Opaqueness’:

 

75% Opaqueness:

 

50% Opaqueness:

 

You can download the class and sample form here (4 kb).

This post originally appeared on the Foxite Weblogs site.

FoxForward – Day Three, Part Two

After my session was over, it was time for lunch. WOO HOO!!!

During lunch, Kevin gave away some more swag, and I was lucky enough to win a Visual FoxPro hat (donated by Jim Eddings at FoxToolBox.com)!

The next sessions were Craig Boyd’s Securing Visual FoxPro Data and John Harvey’s FoxPro and Wireless Data. I had seen Craig’s session at Southwest Fox last year, so I went over to John’s session.

John has built a very impressive application, called WASP, which has increased the effectiveness of law-enforcement officers and improved the productivity for the agencies that use it.

The session was really more of an introduction to the system, and a Case Study-type of presentation. In fact, John has a case study on the Microsoft site. If you haven’t seen it, take a look. Interesting stuff, to say the least, to see all of the integration of products and technologies John uses.

Next up, Bo Durban’s Using GDI+ with VFP and Paul James’ Two-Factor Security for Remote VFP Apps. I wanted to see both of these, but could only choose one. Alas, I went outside during the break (after John’s session), and ended up outside through the next sessions chatting with Craig Boyd and Steve Ellenoff.

Next thing I knew, it was time for the final sessions of the day. Steve Ellenoff was presentingIntegrating USPS Webtools Into VFP Desktop and Web Applications, and Dave Bernard was speaking on Developing with AJAX VFP-Style. I went to Dave’s presentation. He gave an overview of the technologies behind AJAX, an showed off some impressive stuff he’s been involved in.

5:15 PM: The conference has ended. Already? Man, the time flies. I went outside for a while and chatted with Craig and Bo. By that I mean I listened to Craig and Bo, nodding my head in agreement to everything they said, because I was lost right-away. 🙂

I headed back inside to say my final good-byes to my new friends, and then hit the highway for the 3.5 hour drive home.

Last year at Southwest Fox I was a total wallflower, so I tried to open up a bit more and talk with people at FoxForward. I made a lot of new friends, and I’m looking forward to next year’s conference (if there is one, and I hope there will be). I’m also planning to get to at least one meeting for the Atlanta FoxPro Users Group in the near future.

I’m decompressing a bit from the information overload that is typical from a technical conference. But for all the info, tips, tricks, and other great info I picked up, the best part of the conference was talking with other FoxPro developers, meeting great people, and hearing about all the great stuff people are doing with Visual FoxPro.

Kudos to Kevin Cully (and his family), the sponsors, speakers, and attendees.

FoxForward Rocked!

This post originally appeared on the Foxite Weblogs site.

FoxForward, Day Three, Part One

Saturday night…

The final day of the FoxForward Conference was approaching, so I decided not to go out with the guys on Saturday night to the Ale House (the name of the place suggested I would be presenting my Sunday session with a hangover). I went to the deli across the street from the hotel for dinner.

Then I headed back to the room to make sure all my presentation settings were ready. I can’t thank Doug Hennig and Rick Schummer enough for their tips. It was a tremendous help. I recommend their tips to anyone speaking at a conference or user group.

With the Tennessee/Florida football game on for background noise, I figured it was time for just one more walk-through for my session. For the umpteenth time, I ended at the the one-hour mark. For a 75-minute session. I thought, “How in the world am I ever going to stretch this thing out to 75-minutes?”

I’m not a good sleeper when I’m “on the road”, and I found myself still awake at 3:30 AM. Since my session wasn’t until 10:00 AM, I decided I’d sleep in and miss the first sessions (David Greenberg presented Use the FoxPro Grid Control for Added Functionality, and Irv Adams presented Containing FoxPro).

At 9:00 AM, I took a shower. A HOT shower. I mean a really, REALLY H-O-T shower. So hot, in fact, that 5 minutes after drying off I was covered in sweat.

OK, I’ll admit I was a bit nervous about the session, what with the nightmares and all. But still, I think I’ll blame the hot shower for the excessive sweating. 🙂

After drinking a couple of cups of coffee, I headed downstairs, laptop in hand. Chatted with a few people, and had another cup of coffee. Then, I grabbed a couple of bottles of water to have for the session, and headed outside for a quick smoke.

I drank one of the bottles of water while I was outside smoking, so when I went back in I grabbed another bottle.

Took my laptop into the conference room and quickly headed to the men’s room. After three cups of coffee, and one bottle of water — I definitely did NOT want to have to excuse myself during the presentation to go to the men’s room. 🙂

Alan Stevens was presenting Left Behind? Team Foundation Server and VFP in the other conference room. I spoke with Alan on Saturday for a while. Great guy. And he works at DPRA (the JFast guys), so naturally he was sharp as a tack. He had presented the session to the Asheville FoxPro Users Group, and I believe he had done a run-through with the guys he works with, so I expected to see at least the guys from Asheville and DPRA at my session.

I didn’t pay much attention to the room while I was setting up the laptop, so I was a bit surprised at 10:00 AM when I looked up to get started. There were a lot of people in the room! WHEW!!! I’d have been happy if only five or six people had shown up, and I’ve got to say a big ‘ol “Thank You” to everyone who came to the session.

 

I started with an introduction about myself, and my throat immediately began to dry up, so I started on the first bottle of water. Then I kicked into the session. I said this was an “eye-candy” session, then started talking it up. BLAH-BLAH-BLAH.

More water.

I went on and on about “how neat” the Desktop Alerts were.

More water.

How “cool” they were.

More water.

Talk, water, talk, water, talk, water…

Someone from the group said, “Can we see it?”

I had been so busy talking about it, I had forgotten to show everyone what the heck I was talking about, so I promptly ran a litte demo.

About this time, I’m starting to feel a certain, um, urge.

From within.

And it’s starting to get stronger.

While I’m speaking, I’m thinking to myself, “Please, Lord, let me get through the whole presentation before I need to go to the men’s room.”

The more I spoke, and the stronger the urge, the more I began to move around. Walking back and forth — from my laptop to the projection screen and back to the laptop.

Now, this urge is really starting to get stronger and stronger. I thought to myself, “Take a quick peek at the clock on the computer. Maybe my time is about up anyway. Surely I can hold it another 5 minutes.”

I glanced at the clock. It’s 10:40 AM. My session is only HALFWAY done. And this urge is getting ever stronger.

More moving back and forth while I speak. This urge is starting to hurt. I really need to go. NOW.

I fight it. I… must… move… on… Must… fight… urge… keep… tal… k… ing…

Suddenly, I hear the words leave my lips, “I’m really sorry about this guys, but I really need to go to the men’s room.”

I thought, “Did I just say that out loud?”

I glanced around the room. A few people’s faces looked as if they were thinking, “Did he just say that out loud?”

Everyone was really nice about this, and I really can’t thank them all enough for letting me “go” in the middle of the session.

A couple of minutes later, I was back in the front of the room, and I continued on with the session.

I had about four slides left, and quite a bit more demoing to do, when I took a look at the clock. 11:20AM… 11:20 ??? I’m 5 minutes OVERALREADY?

But, I’m only HALFWAY through this thing!!!

I flashed forward to the final slide (with my contact info), and thanked everyone for coming.

During the session, I got some really good questions and suggestions about the desktop alerts. And afterwards, several of the attendees congratulated me on the session — even with my mid-session disappearing act. 🙂

That 75-minutes were the fastest 75-minutes of my life. I can’t thank Kevin enough for allowing me to speak at the conference. I can’t thank the attendees enough for coming to the session and for their comments and interest in the session. I can’t thank Rick and Doug enough for taking their time to help me and others with their tips.

This was fun. A lot of fun. I’d like to do this again. 🙂

Alright. Enough about me. Stay tuned for more from the rest of the final day of FoxForward!

 

Heading Out to FoxForward

I’m getting ready to head out on the 3.5 hour drive to Atlanta for the FoxForward 2006 conference.

Many thanks to Rick Schummer and Doug Hennig for sharing their tips for speakers. As always, great information from great community members. Thanks guys!

What’s on the schedule today?

Looks like it’ll kick-off with a “Meet & Greet” at 4:00PM EDT. Cool! A chance to meet some new friends. Here’s hoping I can overcome my “wallflower disease” and actually strike up a few conversations. But, just in case I don’t, someone, anyone, please feel free to walk up and say “Howdy!”

I’ll be the geeky-looking guy with a black Nike baseball cap.

The sessions begin at 5:00PM EDT, with Dave Bernard presenting Does Your Application Understand You? Using English Query with Visual FoxPro, and Bo Durban presenting Creating Custom Report Controls and Customizing the Report Designer. I’ll probably go to Bo’s session, because after all this time with Visual FoxPro 9, I (shamefully) still haven’t begun to scratch the surface on the new reporting capabilities.

At 6:30PM EDT, Craig Boyd will present VFP World Domination. I’m excited about seeing this one because I’m sure it will help inspire and re-inspire everyone in attendance.

“World Dom-in-a-tion”, eh? Why does that phrase sound so familiar?

Based on the amazing amount of content, enthusiasm, and inspiration Craig has provided via the SPS Blog and his conference and user group presentations, I wouldn’t mind being his clone and carrying the message forward.

Though, like Dr. Evil’s clone, I doubt I could “measure up” to the original.

Here’s hoping for a great weekend!!!