SQL Report initial toggle state - sql

I have a report that contains a table of data this data is set to be intially collapsed using the initial toggle state property setting, however this does not happen the (sub-data) for want of abetter word still appears, and to make things even more confusing the icon that is placed at the side changes from the expected minus in expanded mode to a plus (which I would expect when the data is collapsed)
I have been trying to solve this for hours now but I cannot find a setting that will remedy the situation. I have tried selecting the row and edit group this allows me to set the rows to be exapnded by the relevant parent field, which I do set, but when applying the collapsed setting to the sub data, it is ignored.
Any help would be much appreciated thanks.

there seemed to be a strange error where if i edited the group directyly the group displayed the settings buit the page did nor solved by editing the page settings as well

Related

Can Access ensure a new form record displays all fields?

I have a database where I don't want some fields showing depending on data in other fields. I'm still new to VBA, having learnt how to do things I need via the internet (there's not much call for it in my job so like to try it out on side projects) for the things I need and have managed to create some code that hides certain fields that aren't needed, depending on what's been entered in another field and that works okay, if not perfectly (I'd like it to only work on the current record and not all of them at once but will worry about that later). My problem is, if I'm entering information onto a record and any of those fields become invisible exactly as I would want them to, then if I have more records to complete and load a new record, those hidden fields are also hidden on the blank record before any data has been entered and I want each new record to show all fields from the outset.
Another thing I've noticed is that if I close the database, next time I go into it the hidden fields have unhidden themselves again so I know I'm missing something important.
Here's a screenshot of a bit of the code where I want 2 other fields (What_reason and Date_sent_to_new_owning_School) to be visible depending on whether the answer in the current field after update is "Standard" or "Non-standard":
I'm sorry if this is really entry-level stuff but I AM entry level and trying to learn. This bit does work, albeit not perfectly as I'd like it to only work on the record I'm in at the time, and not go through and hide that field in all the other records at once (which it's doing).
I've searched everywhere but can't find the answer and although I've tried, I'm nowhere near good enough at VBA to try and use common sense to work it out. Is this something that can be done? I'm okay with computers generally and with Access too but I'm aware there's an awful lot I don't know and this is why I'm trying to do new things and learn stuff that I've not used before. I have tried all day to get this to work but am admitting defeat and am hoping somebody here will be able to help me. I'll probably need 'idiot level' advice if that's possible, I know my limitations. :)
Do you know how to use the Event tab in the Property Sheet? You can set all of your fields to [field].Visible = True on either: On Current, On Load, or On Open
Screenshot of the Property Sheet and for the field that determines the visibility of all of the other fields; you can use the Event: After Update so that way when you click/tab away from that field, it'll make those changes for you!
Property setting affects ALL instances of control. Control will be visible/not visible for all records depending on conditions of current record. Therefore, dynamically hiding controls on form set in Continuous or Datasheet will NOT give the desired result of
only work on the current record and not all of them at once
Db is not going to 'remember' dynamic setting - code needs to be executed when form opens and/or navigating records - so it is needed in OnCurrent event as well as control's AfterUpdate.
Conditional Formatting can dynamically enable/disable textbox/combobox by record although control is still visible.

SSRS Reporting - How do you prevent a page break before a row in a Tablix?

I have a tablix that contains a fair bit of verbiage. There are other tablix that contain a user defined amount of information. The tablix that contains the large amount of verbiage comes afterwards. Upon printing the report, the row of the tablix that contains the large amount of verbiage will push to the next page every time. I am looking to prevent this from happening.
I am not using Row Groups.
I have set the Page break options to Keep together on one possible checked and unchecked.
I found putting the tablix inside a text box helps control this. See below:
Another thing that helps is applying filters to the row to handle how many results are displayed. See below:
This should prevent the page over flowing onto the next. To fit as much data as possible on the page you can always change font size or squeeze everything closer together.
Hope this helps.
Thanks
Gav

Access Field Not Refreshing

To start, I am using Access 2003 and have a similar project that works correctly that I designed.
I am stumped as to why a particular field will not change dynamically like every other field until I "refresh".
Currently I have a task list that lists all items that need to be works. Containing a Status: New, Open, Closed; The account number, person who is working it and more.
The tasklist is just a form with a subform with a datasheet view that opens the task when you double click it. If a user opens a task, that task will be locked until they move on. If any information that is viewed in the task list is changed, it dynamically updates, all but the Status (which really is the most important) until the user manually refreshes it.
Does anyone know what I need to look for that would cause this? The Status is stored as an integer that joins with it's true value. I thought this may be the reason, however I have a similar tool I designed does not have this issue.
I've look into how they are joined, the code that changes this value, everything seems the same between the working and not working.
Any advice?
Thanks in advance.
edit any fields that are JOINED, do not seem to dynamically update until I hit refresh. However, the other database has this working. What am I missing that is different between them.
Solved.
I changed the object displaying the field from a textbox to a combobox, showed two columns with widths 0";1" and it works.

Keep Fixed Data row fixed on mutliple pages when deployed

I have a Tablix member that is FixedData and works fine in preview mode.
The problem is once deployed the Fixed Data only shows on the first page, the next page it doesn't work anymore.
You need to enable the advanced mode in the grouping panes.
Once you enable the advanced mode you will see static groups in your grouping pane. when you select static group you will notice that corresponding cell in the table will be highlighted.
Goto the desired cell by selecting the appropriate Static Group. In the properties window of that static group set RepeatOnNewPage to True and KeepWithgroup to After
Now you are all set to show data row on multiple pages.
HTH.
Recently I experienced something similar its rather strange but SSRS play funny games sometimes.
I deleted the Data Source and created again and it started working
God knows why but it worked for me.
Another thing sometimes If
screen display settings are set to medium some times the report data
doesnt display but when you export from the reportviewer to some
excel or so you can actually find all the data.
One last thing try it in a different browser preferably IE.

Masked Text Box removes preceeding zeros in date

I have a process which grabs the birthdate and from a data table and display them in a masked text box for viewing and editing
However when pushing the data into the textbox any preceding zeros get removed
For example 05/05/2005 would display as 55/20/05__
The masked Text box is set up as 00/00/0000
The line which assigns the code is:
MaskedTextBox.Text = Format(DataTable(0)("DOB"), “MM/dd/yyyy”).ToString
To date I have tried the following:
Delete and re-add the control
Copy masked textbox from another form
in the same program
Above Masked textbox grabs the same
information from the same database
table and is formatted exactly the
same and it works
Tried various different formats
including no format all with the same
result
Does anyone have any other suggestions?
I've been able to replicate the problem but currently there doesn't seem to be a solution. What you need is a binding navigator toolbar on the top of your form with your data bound masked text box with any mask (doesn't matter which one). When you run the form, initially the masked text box will accept the data just fine. However, if you click the "AddNewItem" button (the plus sign button) on your binding navigator toolbar, it will cause the masked text box to delete all preceding zeros when you try to enter a date. It seems all masks will do this. Rebuilding the form won't fix it, either. It happens every time you hit the "AddNewItem" button and then proceed to enter data into any formatted masked text box.
Now that I've found out exactly how to replicate the problem, hopefully someone more knowledgeable can come along to figure out how to circumvent this. It seems like it is a glitch within VB. Don't know if this constitutes as an actual "answer" but I have provided a clear path to finding a solution. I just don't have the know-how to get that far.
(Update: I discovered that it does this to all masks, not just "short date" masks)
I think I am going to have to put this in "Mysteries of the Unexplained " box.
At the advice of another developer I manually recreated the form, re-added all the controls and it now works fine (copy and pasting all the controls from one form to another caused the issue to come with it).
I really don't know how to even recreate the issue must be something in the forms design level code???
Anyway thanks for all the assistance from everyone.
Try converting the Datatable data to date and back:
MaskedTextBox.Text = Date.Parse(DataTable(0)("DOB")).ToString("MM/dd/yyyy")
My guess is that either the database is sending the date in a format you don't expect, you changed the control's Culture (under Behaivior properties), or that you changed the way your computer shows dates and thus changed its culture. However I try I can't replicate the problem with my culture settings.
I had the same problem with Masked a Text Box control that was added at runtime. I was just trying to add the date of the day to the control
Visual studio 2013
Dim Today As Date = Now.Date
tbox_ShipDate.Text = FormatDateTime(Today,DateFormat.ShortDate) 'Failed every time
Problem was solved by using
tbox_ShipDate.Text = Format(Today, "MM/dd/yyyy")
seemed to simple but all worked well