If you are reading this, I am assuming that you've read my article on HOW TO CREATE AND ADD A NAMED LOCAL DATABASE INSTANCE IN VISUAL STUDIO 2013 . Now to add the local database file to your published application, first you need to make sure that the database.mdf file is in your project folder. Then go to solution explorer and click on "properties". go to "publish" and click on "application files" ensure that your database.mdf and database.ldf files are there. Then go to solution explorer and create a new "setup" project (unless you have an existing setup project). Right click on the setup and go to "view" then open "file system". Open the "application folders" by the right. Then right click on an empty space and select "add" then "files..." it will open a windows explorer for you to locate and add your database.mdf and database.ldf files. Then you can build your setup and publish your application.
Note: for the published application to access your database after installation by and end user. you'll need to adjust your connection string to the database a little. where it is written "attachdbfilename:" change the database path to "AttachDbFilename=|DataDirectory|\database.mdf". This will allow your published application to access the database file no matter the path it installs it to.
This is a site for - the latest solutions to technical problems, life facts, jokes and also a site created for solving math problems. If you have any technical question or problem, write it in the comment box and I shall upload the answers.
Wednesday, 21 September 2016
HOW TO CREATE AND ADD A NAMED LOCAL DATABASE INSTANCE IN VISUAL STUDIO 2013
To create a database file in your visual project, go to the "add new item" and add a service based database file, then in your solution explorer, double click on the .mdf file. The database instance opens in server explorer automatically. right click on the database instance and click on "modify connections" (before you do this make sure you close the connections first). Click on "Change..." and in the new tab select "Microsoft SQL Server". when the former tab reopens type "(LocalDB)\v11.0" as your server name. click on the radio button "attach a database file". Select browse, and browse to the database.mdf file which you created (It is located in your project folder by default). After selecting the file, give the project a logical name of your choice (do not use punctuations because this might affect its backup if you want to put a backup code). click ok.
To get the connection string for your database instance, go back to "modify connections", click on "advanced", copy the connection string which will appear at the bottom of the new window.
To get the connection string for your database instance, go back to "modify connections", click on "advanced", copy the connection string which will appear at the bottom of the new window.
Thursday, 25 August 2016
FIX NETWORK, BLUETOOTH, USB AND OTHER DEVICE ERRORS
Whenever you are experiencing problem or errors in your network, Bluetooth etc. The fix is usually simple. Go to device manager and find the driver related to your problem (ie if network problem you select network drivers) now once this is done you update the present drivers. If updating doesn't solve the problem or perhaps the driver is already up to date. Try roll back update if the option is available. In a case where neither of this works. Try reinstalling the driver or finding another driver in your computer. You can do this by clicking on update driver, it'll then provide you with options of either going to the internet or providing a path in your system. Select the second. If you don't know the path where it is. You select the option "let me pick from a list of drivers".
Wednesday, 24 August 2016
HARDWARE ACCELERATION ERROR ON WINDOWS (SOLUTION)
The hardware acceleration error is usually due to some system parameters not being up to date. So when this occurs try updating your device drivers. If this doesn't solve it then you know the fault is from another parameter. In order to fix it permanently, do a windows update of your system. You can do this by going to control panel and then enter windows update, either download the available update or check for new updates.
Friday, 19 August 2016
FIX VMWARE GUEST OS COPY AND PASTE PROBLEM
Most of the time when VMware guest OS has copy and paste problem it is usually a fault from the VMware tools which is normally installed into the guest OS. To fix that problem your can search for the fix on google or you can download VMware tools and reinstall into the guest OS. But that is not the only thing that can cause a copy and paste problem. I recently discovered it can be caused by uninstalling Microsoft visual c++ from control panel. This recently happened to me and the way I resolved it was by restoring my system to a previous state. Just so you know, you shouldn't uninstall Microsoft applications in your control panel anyhow. It can affect your system.
THE BEST VIDEO CONVERTER
There is a video converter for making your video files compatible with any device at all, no matter the video format it will make it play on the device you want it to play. This video converter software is "any video converter" and you can download it here
Friday, 12 August 2016
HOW TO RE-INSTALL PLAY STORE AFTER UNINSTALLATION OR AN ERROR
If you by any chance uninstall your play store and cant re-install it or perhaps the one you installed is showing error. Don't worry, the only problem is that you didn't get the exact latest version compatible with your phone. Therefore it is necessary that you search for the latest version compatible with your phone, and not just install anyone you see from a website or file share. First you need to go to settings in your phone and click on "about phone" so you can know the android version you are running on. Once you know this you can then click here, and find the play store compatible with your phone. When you open each play store on the link, check where they wrote minimum android version and make sure your android version is higher than the minimum, else find another one.
Monday, 8 August 2016
EXTEND OR GET EXTRA LIVES IN CANDY CRUSH FOR FREE
This method is a temporary means of getting extra lives in candy crush and any other game application that uses time for lives. All games that use time for the extra lives uses "system time". That is to say that they calculate the time remaining from the time you set on your phone. Therefore if you want to add say like 5 lives in candy crush, whereby each life takes like 30 minutes you are to increase or add 2 hours 30 minutes to your phone time. This will automatically give you full lives. (NOTE: Do not add more than 5 lives cos no matter how much more time you add. candy crush will only give you 5 lives at once). Now the consequence of this little tweak is that when you switch back your time to normal the game will detect it and wait till after 2 hours 30 minutes to give you any more lives. So you can increase the time in order to play the game during the day, then once you are done playing and go to sleep at night, you'll make up for all the time you added. Have fun!
Friday, 29 July 2016
SQL CONFIGURATION MANAGER LOCATION AND ACCESS
To locate the sql configuration on any machine follow the path
these respective paths will open the configuration manager.
NOTE: this path must be followed and not from its shortcut or from desktop. Else it won't load properly in some areas. Ensure you open the file itself from the specified path and not a shortcut.
| SQL Server 2016 | C:\Windows\SysWOW64\SQLServerManager13.msc |
| SQL Server 2014 | C:\Windows\SysWOW64\SQLServerManager12.msc |
| SQL Server 2012 | C:\Windows\SysWOW64\SQLServerManager11.msc |
| SQL Server 2008 | C:\Windows\SysWOW64\SQLServerManager10.msc |
NOTE: this path must be followed and not from its shortcut or from desktop. Else it won't load properly in some areas. Ensure you open the file itself from the specified path and not a shortcut.
Wednesday, 27 July 2016
HOW TO CONNECT VMWARE HOST MACHINE NETWORK TO VIRTUAL MACHINE
In order to connect a virtual machine to its host network a router is required. That is, if you want network communication with your host machine and your virtual machine you to be connected to a WIFI network or modem which will create a network connection and assign IP addresses to the two machines. If you create this connection and it doesn't work, go to "edit" tab in VMware and select "virtual network editor". In the window that opens select "change settings" (you need administrative privileges to do this), and then click on "restore defaults". When it is done click ok and close the window. then open the virtual machine you want to connect to. On its open window click on "edit virtual machine settings" and navigate to network adapter and set it to "NAT". Once you are done the connection should be made. Ensure that you are connected to a WIFI or modem because it will act as a router.
Wednesday, 20 July 2016
HOW TO FIX ASPHALT 6 IN TECNO D3 AFTER DELETING SHARK DASH OR LITTLE BIG CITY
First of all you should know that the asphalt 6 that comes with the Tecno D3 phone is not a standalone. It works with shark dash, little big city and some other apps that came with the phone. It is important that u don't force stop, uninstall or delete any of these apps if you want to keep running asphalt 6 in your phone. But in an event that you delete it without knowing don't worry... just go to your folders under sdcard/APKS and you'll find all your follow come apps for re-installation. There is a follow come sd card in Tecno D3 phones and that's where the directory is. But in an event where any of these cant be found... download the apps from here.
Sunday, 10 July 2016
HOW TO FIX A SPOILT RECHARGEABLE FAN
When a rechargeable fan is spoilt from the inside its very easy to bypass the problem and keep using the fan. All the fan needs to rotate is direct current (DC) which is produced by a battery cell inside the fan. So when the whole charging system of the fan spoils and the fan is not working anymore, just cut out the wire coming from the rotating head and connect it directly to the battery (i.e connect the negative wire or blue wire to the negative or blue side of the battery, Do the same for the positive or red wire). Now the issue that'll arise will be getting the battery to charge cos the battery will die eventually.
Now to charge the battery you can use the fan charger (IF ONLY IT HAS ITS OWN BUCK BOOST CONVERTER OR POWER PACK AS IT IS CALLED, AND MAKE SURE THAT IT IS NOT FAULTY) by cutting out the mouth that goes to the fan, then bring out the two wires on the inside the red one is positive and the blue is negative by default, but if yours doesn't have color you can determine which is which using a galvanometer/voltmeter. Now do the same connection for the charger as you did with the fan, i.e plugging positive to positive and negative to negative.
NOW IF YOUR FAN CHARGER IS AN ORDINARY WIRE AND DOES NOT HAVE POWER PACK OR IF THE POWER PACK IS FAULTY. you can use laptop charger with a working power pack to charge it on the following conditions.
1. You must find out the voltage rating of the power pack.
2. You must ensure that the voltage rating of the power pack is greater than the voltage of the battery. The voltage rating of the power pack below is 19 volts.
3. You must ensure that the power pack rating is not more than 5 volts higher than the battery voltage (i.e battery voltage4. If your fan has two batteries make sure the sum of the voltages of the two batteries satisfies conditions 1,2, and 3. And when connecting the batteries for charging connect it in series.
The above conditions MUST be satisfied for the charging to work. If the voltage rating of your battery is too high you could connect a resistor or any DC appliance that'll lead to a voltage drop.
Now to charge the battery you can use the fan charger (IF ONLY IT HAS ITS OWN BUCK BOOST CONVERTER OR POWER PACK AS IT IS CALLED, AND MAKE SURE THAT IT IS NOT FAULTY) by cutting out the mouth that goes to the fan, then bring out the two wires on the inside the red one is positive and the blue is negative by default, but if yours doesn't have color you can determine which is which using a galvanometer/voltmeter. Now do the same connection for the charger as you did with the fan, i.e plugging positive to positive and negative to negative.
NOW IF YOUR FAN CHARGER IS AN ORDINARY WIRE AND DOES NOT HAVE POWER PACK OR IF THE POWER PACK IS FAULTY. you can use laptop charger with a working power pack to charge it on the following conditions.
1. You must find out the voltage rating of the power pack.
2. You must ensure that the voltage rating of the power pack is greater than the voltage of the battery. The voltage rating of the power pack below is 19 volts.
3. You must ensure that the power pack rating is not more than 5 volts higher than the battery voltage (i.e battery voltage
The above conditions MUST be satisfied for the charging to work. If the voltage rating of your battery is too high you could connect a resistor or any DC appliance that'll lead to a voltage drop.
Tuesday, 5 July 2016
YOU REPLACE EVERY PARTICLE IN YOUR BODY EVERY SEVEN YEARS.
Red blood cells live for about four months, while white blood cells live on average more than a year. Skin cells live about two or three weeks. Colon cells have it rough: They die off after about four days. Sperm cells have a life span of only about three days, while brain cells typically last an entire lifetime (neurons in the cerebral cortex, for example, are not replaced when they die).
There's nothing special or significant about a seven-year cycle, since cells are dying and being replaced all the time. It's not clear where this myth began; perhaps some well-meaning but innumerate person simply added up the all the lifespans of the body's various types of cells and (mistakenly) assumed that all the cells are renewed after seven years.
Monday, 4 July 2016
HOW TO USE EDMX FILE AND OBJECT QUERY IN VISUAL 2012 AND LATER
In order to use object query in your program you'll need to include include system.data.entity as a reference in your project. To do that you go to "references" click on "add reference" and you find it and add it, after adding it you'll include in your code "using system.data.objects;". Now in order to use the edmx file with object query object context there are things you need to understand. object context is a form of db querying used in older visual studio versions, the one used in visual 2012 and later is dbcontext. Therefore in order to use object context in visual studio 2012 and later you'll need to revert your entity framework to the format used in older visual studio. To do this... First you'll go to the edmx model, click on an empty space, then go to properties. You'll notice that "code generation strategy" is set to T4 without any option for you to change it. This occurs in entity framework versions 5 and later which you'll find in visual studio 2012 and later. in older versions you are given a choice between "T4" and "Legacy object context"- which doesn't appear in entity framework 5 or later - Now in order to use object context, you'll need to add entity framework 4 to your project. this is done by going to tools - nuget package manager - package manager console. When it opens well, type in "install-Package EntityFramework -Version 4.3.1" or any other version 4 you want. and allow it to install. when it is done, you then go back to code generation strategy, and you'll see that legacy object context has been added. Now when you are done you go to your Project solution folder and find the folder for edmx model. click on its arrow to drop down. Then delete all the ".tt" files because those files are generated only for T4. Therefore once you've changed to legacy object query you delete the .tt files. Now in that edmx folder you can open edmxModel.designer.cs file (depending on the name you gave it). You'll notice that when the code generation strategy was in T4 there was no code there but after changing to legacy object context some codes are automatically generated in it. Now with this done you can now use emdx file with your object query in visual 2012 or later. thanks.
Subscribe to:
Posts (Atom)
