Critical current densities of superconducting materials can either be measured by direct current measurements, or indirectly by magnetic flux measurements. The disadvantage of the direct method is the much higher resistance of the measurement contacts in comparison to the superconductors resistance. The indirect method on the other hand measures the magnetic moment. In order to calculate the current density, the geometry of the superconductor needs to be known. Additionally, demagnetizing effects modify the magnetic field in the sample. The purpose of this thesis is to investigate the demagnetizing effects on the critical current densities in type-II superconductors. The insights from this thesis are meant to help calculating the demagnetizing effects, especially of magnesium diboride multifilament superconductors, in the future. Regarding the theoretical calculations, formulas for the magnetic moment were derived in great detail for several geometries, including cylinders, cuboids, hollow cylinders and elliptic cylinders. Furthermore, the demagnetization factors for a cylinder and an infinite long bar have been computed. Also, a new formula to calculate the current density of the magnetic moment of cuboids and cylinders was proposed. Niobium cylinders and cuboids of several lengths were measured by magnetic flux measurements in order to compare the critical current densities and the magnetization values with the theoretical calculations. Depending on the regarded geometry, two formulas relating current density to magnetic moment are usually used. The first formula is used to calculate the magnetic moment of geometries where one of two dimensions perpendicular to the applied magnetic field, is much longer than the other one. The second formula is used for geometries where both of the dimensions located perpendicular to the magnetic field are almost equally long. In this thesis, these two formulas are compared and the differences between them are discussed.