Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Progress Bar Makes Form Transparent

Status
Not open for further replies.

SeaRay

Technical User
Jan 8, 2002
20
US
Using Access, I put a progress bar on a form that launches when I run code. When the form launches, the form becomes transparent. You can still see the progress bar and the frame of the form, but the background is transparent. Why is this happening and what can I do to stop it?

Thanks, Rick Ruscin
 
Hi Rick,

One thing that would cause a form to be transparent is if the appearance property is set to flat,try 3D

Jon
 
The 3-D setting did not change anything...
Any other ideas?
 
Hi Rick,
I've been playing around with ProgressBar on a form/project I have and it seems to work well. I can't find any property or method of it that would effect the form itself. I'm wondering what code,if any, you have in Form_Load() or sub main that might affect the form. I'm all out of suggestions myself.

Jon
 
I just made an unbound form and put a Microsoft Progress Bar 6.0 on it from the tools menue. Then from another form, I put a button that runs code that loops through sets of records. Written in the same code, I have it launch the form with the progress bar and scroll it. If you just open the form by clicking on it, the form is not transparent. However, if the code launches it and scrolls the progress bar, the form is transparent. The first part of the code looks like this...

Private Sub Import_Click()
Forms![Daily Sales].Visible = False
DoCmd.OpenForm "frmPBar", acNormal, "", "", , acNormal

Forms!frmPBar.ProgressBar1.Value = 0
Forms!frmPBar.ProgressBar1.Max = 1000
Forms!frmPBar.ProgressBar1.Value = 0

DoCmd.DeleteObject acTable, "tblprod"
On Error Resume Next

DoCmd.DeleteObject acTable, "tblCredit"
On Error Resume Next

DoCmd.DeleteObject acTable, "tblDept"
On Error Resume Next

DoCmd.DeleteObject acTable, "tblDisc"
On Error Resume Next

DoCmd.DeleteObject acTable, "tblTtlzr"
On Error Resume Next

Forms!frmPBar.ProgressBar1.Value = 100

Dim strPathName As String

strPathName = (DatePart("d", [Forms]![Daily Sales]![Date]))

DoCmd.TransferText acImportDelim, "ProdSpec", "tblProd", "C:\Program Files\SSM\Day\" & strPathName & ("\Prod.txt")

Forms!frmPBar.ProgressBar1.Value = 200
 
To try to isolate when the form becomes transparent, I interupted the code with a message box in different spots. The strange thing is that when I interupt it, no matter where, the form does not become transparent, even after you click OK...

I am really baffled.

Rick Ruscin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top