SkipVought, thanks for your input.
After inserting your code to test out, my script still cannot find the file..?
Sub read()
'read Macro
'Keyboard Shortcut: Ctrl+Shift+R
'
Dim sPath As String, sDB As String, sConn As String
sPath = ThisWorkbook.Path
sDB = "yearly_stats.txt"
sConn = "TEXT;" &...
What my VBA script does is get external text data and store it in the first few columns. Then this data is used to create several graphs which are exported as .png images.
The problem is that I need to be able to pass my Perl, Fortran, and VBA scripts to another machine within a folder, have...
macropod, thank you for your input. I will move this post on to the VBA forum.
In response to your answer, I'm confused by what you mean exactly, so I want to explain my problem a bit better. What my VBA script does is get external text data and store it in the first few columns. Then this...
A text file is created in the same directory as my .mxls file, which I want to be automatically read-in upon opening. How do I specify the location of the file without using an absolute path (I want to be able to send a folder with the excel file and the text file to another machine)?
Thanks...
Hey Gerrit,
Maybe fail was the wrong word.. Both scripts run without crashing. However, once the 'ifinal.f95' script is finished, the results are all zero (incorrect). Strange, since I've only altered the data file name.
Thanks,
Dave
Hello,
The two attached .f95 scripts are identical, except for the data file which is read-in. I would really love it if someone could tell me why the 'ifinal.f95' scripts fails to produce results..?
Thanks,
Dave
Hello,
I need to automatically export three charts as .png files and save them somewhere on my machine. I found a user-made add-in here that can save excel charts as images to any location, but I can't seem to code a module that automatically does this for 3 charts...
What I did was install...
...= runs(midpoint)
yrstats(updown,year,1) = totalcount
yrstats(updown,year,2) = totalrun
yrstats(updown,year,3) = mean
yrstats(updown,year,4) = median
end do
end do
write(*,fmt='(1XI4,1XI1,1XF3.0,1Xf4.0,1XF6.4,1XF2.0)') yrstats(:,:,1:4)
end subroutine...
...do i = 1, k-1
imin = rlens(i)
iminp = i
do q = i+1, k
if(rlens(q) < imin) then
imin = rlens(q)
iminp = q
end if
end do
t = rlens(i)
rlens(i) = rlens(iminp)
rlens(iminp) = t
end do
write(*,*) rlens
end do...
The attached .f95 code does a range of statistical manipulations to a large data set. The program had successfully deduced all instances of x > threshold and x < threshold for each of the 42,000+ instances and written them to file. The specific application is daily high temperatures exceeding or...
...been successful in writing the results to a text file, but am unable to store them in an array within the subroutine and print it to the terminal.
***Derived Type Definition***
module my_temps
type temps
integer :: dates, hi, lo, av
real :: hinorms, lonorms
end type temps
contains...
I was looking for some advice on the best method for the following problem:
I have three arrays of equal length... One of dates, of of high temperatures and one of normal temperatures. The goal is to find the longest stretch of days in which high temp > normal temp, and also the longest stretch...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.